View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
Chris Chris is offline
external usenet poster
 
Posts: 788
Default macro to unlock and lock cells in password protected sheet

Hi all

Is there any way I can get a macro to unlock cell, paste valuse and the lock
again after completion. I have a macro to transfer valuse from one rang to
another. The macro will work ok if I leave the input cells unlocked. I would
like to be able to lock these cells so they can't be changed without the the
use of the macro. The input cells are F23:F23. See Code Below.
Regards
Chris
Sub update()



Worksheets(13).Range("I20:I23").Copy
Worksheets(13).Range("F20:23").PasteSpecial Paste:=xlPasteValues
Application.CutCopyMode = False




End Sub