I need to crate a macro that will force the user to save the file as a different name when they open the file
I have this code and it works. I just need to have it run when the file is opened. Is there an on open function that I can add to make it do this?
Sub FS()
'fileSaveName = Application.GetSaveAsFilename(fileFilter:="Excel Files (*.xls), *.xls")
fileSavename = Application.GetSaveAsFilename( _
fileFilter:="Excel Files (*.xls), *.xls")
'If user specified file name, perform Save and display msgbox
If fileSavename <> False Then
pointPos = InStrRev(fileSavename, ".")
fileSavename = Left(fileSavename, pointPos - 1) & Mid(fileSavename, pointPos)
ActiveWorkbook.SaveAs Filename:=fileSavename, FileFormat:=xlNormal
MsgBox "Save As " & fileSavename
End If
End Sub
Thanks a bunch.
Bookmarks