Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I am wanting to create a conditional format or a data validation to protect a
cell if anything other than "New" exists in the cell, so that unless someone has the password to unprotect the sheet they cannot change the cell value unless "New" already exists. I cannot figure out how to do this. If you can help me, please post a reply. Thank you. |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
one way.
Sub lockselect() Sheets(1).Select Sheets(1).Unprotect ("mypass") Range("C1:C15").Select Cells.Locked = True For Each Cell In Selection If Cell.Value = "new" Then Cell.Locked = False Next Cell Sheets(1).Protect ("mypass") End Sub You can use this macro each time the file is opened. To make it work as a trial you have to protect the sheet first with mypass as the password. Range C1 to C15 need to be adjusted to suit. Regards -- Greetings from New Zealand "2442" wrote in message ... I am wanting to create a conditional format or a data validation to protect a cell if anything other than "New" exists in the cell, so that unless someone has the password to unprotect the sheet they cannot change the cell value unless "New" already exists. I cannot figure out how to do this. If you can help me, please post a reply. Thank you. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Conditional format for cells. | New Users to Excel | |||
Conditional Format based on Other Cells | Excel Discussion (Misc queries) | |||
Conditional Format based on 3 other cells. | Excel Discussion (Misc queries) | |||
Copying a conditional format to several cells | Excel Discussion (Misc queries) | |||
Creating a conditional format for a cell based on another cell's v | Excel Discussion (Misc queries) |