View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
DataMouse.biz
 
Posts: n/a
Default Validation & Protection

If you know the range, you can specify in the example given
Range("start","end")

If you want to loop through cells, that can be done with a FOR NEXT loop -
but I'd need to know which cells you want to protect...
Then you call functions to protect ot unprotect:

Function UnprotectCell()
'unprotect/unlock cell
ActiveCell.Select
ActiveSheet.Unprotect
Selection.Locked = False
End Function

Function ProtectCell()
'unprotect/unlock cell
ActiveCell.Select
ActiveSheet.Unprotect
Selection.Locked = True
End Function





"abcdexcel" wrote:


Wish U the same.

Thanks for replying. That will certaining help me.

But I need a code for the entire column / row. A code with a loop or
something like it.

Thanks & Regards,
Aamir


--
abcdexcel
------------------------------------------------------------------------
abcdexcel's Profile: http://www.excelforum.com/member.php...o&userid=30021
View this thread: http://www.excelforum.com/showthread...hreadid=497330