J
julief
I am trying to have a macro open a view on a worksheet and really want to
have the worksheet protected. If i set a worksheet password the user is
prompted for it when they click on the macro button, is there any way i can
inlcude the password in the macro? I would also like to protect the
worksheet once the macro has been run.
The macro is as follows.
ActiveSheet.Unprotect
ActiveWorkbook.CustomViews("2 - Monday View").Show
ActiveSheet.Protect DrawingObjects:=True, Contents:=True,
Scenarios:=True _
, AllowFormattingCells:=True, AllowFormattingColumns:=True, _
AllowFormattingRows:=True, AllowSorting:=True
Range("L9").Select
End Sub
have the worksheet protected. If i set a worksheet password the user is
prompted for it when they click on the macro button, is there any way i can
inlcude the password in the macro? I would also like to protect the
worksheet once the macro has been run.
The macro is as follows.
ActiveSheet.Unprotect
ActiveWorkbook.CustomViews("2 - Monday View").Show
ActiveSheet.Protect DrawingObjects:=True, Contents:=True,
Scenarios:=True _
, AllowFormattingCells:=True, AllowFormattingColumns:=True, _
AllowFormattingRows:=True, AllowSorting:=True
Range("L9").Select
End Sub