Locking cells

  • Thread starter Thread starter Patrick Simonds
  • Start date Start date
P

Patrick Simonds

I use the code below to lock worksheets in my workbook and it works fine,
but now I need et to prevent selection of locked cells. I tried adding ,
EnableSelection = xlUnlockedCells to the end of the statement but I get an
Expected: Named parameter error

SH.Protect DrawingObjects:=True, Contents:=True, Scenarios:=True
 
Never mind I figured it out. Had to add a new line SH.EnableSelection =
xlUnlockedCells
 

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

Similar Threads

Strange worksheet protection behavior 5
Not Select locked cells 0
cell locking problem 1
Protect sheets 6
Phantom sheet protect 4
Protect a sheet 3
Lock Range of Cells 1
Protecting Embedded Chart 1

Back
Top