dariuzthepole
Board Regular
- Joined
- Jul 23, 2008
- Messages
- 111
Hi All,
I have a macro in a protected sheet that pastes an image into it. I want that image to be unlocked so it can be selected and copied. I know you can right-click and unlock the image after it has been created, but this cannot be done when the sheet is locked.
My code is below and the .Locked line is wrong. Any ideas on the correct syntax? Thanks in advance for your help.
I have a macro in a protected sheet that pastes an image into it. I want that image to be unlocked so it can be selected and copied. I know you can right-click and unlock the image after it has been created, but this cannot be done when the sheet is locked.
My code is below and the .Locked line is wrong. Any ideas on the correct syntax? Thanks in advance for your help.
Code:
Dim sh As Object
Range("H7:S59").Select
Selection.CopyPicture Appearance:=xlScreen, Format:=xlBitmap
Range("V11").Select
ActiveSheet.Paste
With ActiveWindow.Selection.ShapeRange
.LockAspectRatio = True
.Top = Range("V11").Top
.Left = Range("V11").Left
'.Height = 183.064
.Width = 105.965
.Visible = True
.Locked = False