In a macro I need for a message to appear warning that cells are protected.
I know of this code, when only one cell is involved:
or![]()
If Range("A1").Locked Then MsgBox "The cell is protected"
But this time I have a range of cells to be written on, say A5 to D9.![]()
If ActiveCell.Locked Then
What would the “If...” code be for the message to appear in case only one cell, any one, or any several cells within that range, are locked?
Thanks for any help.
ACA
Bookmarks