Hi Mr Excel Experts,
Im looking at a way that will enable me to run the following VBA Sub which works and does the SaveAs and opens in the new document but what i want is for the next step is to either Delete or disable the Sub in the new document and leave the orignal document alone. Is this something that can be done????
TIA for any assistance
Thanks
Donald
Im looking at a way that will enable me to run the following VBA Sub which works and does the SaveAs and opens in the new document but what i want is for the next step is to either Delete or disable the Sub in the new document and leave the orignal document alone. Is this something that can be done????
VBA Code:
Private Sub Workbook_Open()
Dim FileSaveAsName As Variant
Dim intchoice As Integer
Static saveProcess As Boolean
Application.EnableEvents = False
ActiveWindow.ScrollRow = 1
Set FileSaveName = Application.fileDialog(msoFileDialogSaveAs)
FileSaveName.InitialFileName = ThisWorkbook.Name
FileSaveName.FilterIndex = 2 'select to save with a ".xlsm" extension
intchoice = FileSaveName.Show
If intchoice <> 0 Then
FileSaveName.Execute
End If
Application.EnableEvents = True
End Sub
TIA for any assistance
Thanks
Donald