Thread: cell lock
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 6,953
Default cell lock

ActiveSheet.Unprotect
set rng = ActiveSheet.Cells.SpecialCells(xlConstants)
rng.Locked = True
ActiveSheet.Protect

--
Regards,
Tom Ogilvy


" wrote:

dearr
i have a sheet that is being updated from a form.
i want the button on the form to lock the cells in which data has been
entered and the empty cells remain unlock.

any help will be appreciated

thanks
naweed