L
Lester from AUS
I am contracting an excel template and need to stop users saving the file
using “Save†or “Save Asâ€. I am able to do this by using the private sub
below:
Private Sub Workbook_BeforeClose(Cancel As Boolean)
Me.Saved = True
End Sub
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
Cancel = True
End Sub
I also understand that by switching to “Designer†mode you can save the file
and once re opened designer mode will be switched off. What I need is to
allow saving using a macro, is there a code that I can insert in the macro to
switch designer mode?
Many thanks for your help
using “Save†or “Save Asâ€. I am able to do this by using the private sub
below:
Private Sub Workbook_BeforeClose(Cancel As Boolean)
Me.Saved = True
End Sub
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
Cancel = True
End Sub
I also understand that by switching to “Designer†mode you can save the file
and once re opened designer mode will be switched off. What I need is to
allow saving using a macro, is there a code that I can insert in the macro to
switch designer mode?
Many thanks for your help