Sheet protection and cell fomat changes

S

Stephen

Hi Folks,

i have a macro which automatically protects all the sheets in a workbook.

Dim ws As Worksheet
For Each ws In ThisWorkbook.Worksheets
ws.Protect Password:="my password here"
Next ws

but i need to allow users the aboloty to change the format options of any
cells even if they are locked.

any help is greatly appreciated.

thanks!
 
V

Vergel Adriano

ws.Protect Password:="password", AllowFormattingCells:=True,
AllowFormattingColumns:=True, AllowFormattingRows:=True
 
S

Stephen

you rock!

thanks!

Vergel Adriano said:
ws.Protect Password:="password", AllowFormattingCells:=True,
AllowFormattingColumns:=True, AllowFormattingRows:=True
 

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