Disable the name box

O

onedaywhen

What do you mean by 'disable'? If you protect the worksheet (Tools,
Protection) the names can be viewed and selected, but not changed,
from the 'name box'. If you make the names hidden they do not appear
in the 'name box' nor the 'Define Name' dialog (Insert, Name, Define).
You must set the Visible property in code e.g. in the VBE Immediate
Window:

for each n in ThisWorkbook.Names : n.visible = false : next

The above code is also a heads up: the user can access (view, make
visible, change, delete) your defined names using the Immediate
Window, even when the worksheet and workbook is protected.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top