Hi,
I'm a novice, and I have a spreadsheet that I want users to save only via a button on the worksheet. I have found code that prevents saving, which is great:-
[code]
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
MsgBox "This workbook can ONLY be saved with the Save Button"
Cancel = True
End Sub
[code/]
but then my save as Macro wont work either...
[code]
Sub Saveasdate()
Dim strName As String
Dim strPath As String
Application.DisplayAlerts = False
strName = Range("AL3").Value
strPath = ActiveWorkbook.Path
ActiveWorkbook.SaveAs Filename:=strPath & "\" & strName, FileFormat:=xlNormal
End Sub
[code/]
Can someone help me to do this better, or somehow turn saving back on when I need it?
Thank you
Bookmarks