This would be language independent
Code:.Value = Not(CStr(.Value) = CStr(True))
It is possible to have words other than True and False.
Actually, I would recommend that the cells get their color from Conditional Formatting rather than by the DoubleClick event.
It is possible to have words other than True and False.
Actually, I would recommend that the cells get their color from Conditional Formatting rather than by the DoubleClick event.
.Value = IIF(CStr(.Value) = "Y", "n", "Y")
Assuming the cell is never blank, this should also work...To use Y/N rather than TRUE/FALSE change this line
Code:.Value = IIF(CStr(.Value) = "Y", "n", "Y")
IMO, assuming what users will put in a cell (inadvertently or otherwise) is a bold move.Assuming the cell is never blank, ...
When I do that, it is to set the limitations for the formula or code I am posting... that way the OP knows right away whether he/she can use it or not.IMO, assuming what users will put in a cell (inadvertently or otherwise) is a bold move.
To use Y/N rather than TRUE/FALSE change this line
Code:.Value = IIF(CStr(.Value) = "Y", "n", "Y")
And later adjust the testing to set the colors.
When I do that, it is to set the limitations for the formula or code I am posting... that way the OP knows right away whether he/she can use it or not.