Hi all
I've created a Userform to give an admin user a mini dashboard to manage various workbook properties, including worksheet and workbook protection.
One of the options is for the user to password protect all worksheets, and I thought I could use a ComboBox for the user to select their preferred cell selection option.
So, on the UserForm I have the following:
A textbox to enter a password [tbxWSPW]
A command button to protect the worksheets [cmdWSProtect]
and a ComboBox [cbxCellSelection] to choose one of three cell options - xlNoRestrictions, xlUnlockedCells and xlNoSlection.
The code I'm using is as follows:
But, when I run this I keep getting a Type Mismatch error on the ws.EnableSelection line.
I have two questions:
1. How do I fix the above?
2. If I wanted to control the other properties (for example DrawingObjects, Scenarios etc), could I do this using checkboxes (ie: ticked for True, unticked for False), and how would I code this?
Many thanks everyone
Stephen
Bookmarks