MrExcel Publishing
Your One Stop for Excel Tips & Solutions

Excel Save As Macro


Posted by KLove on August 01, 2001 2:05 PM

I need excel macro to utilize the Save As Dialog Box for a template. Each time a user enters data can hit the Save As Button on form and it will save the file with a new file name. This needs to be a xls extension.


Posted by Cory on August 01, 2001 2:43 PM

See if this will work:

Private Sub CommandButton1_Click()

Dim Fs As String

Fs = Application.GetSaveAsFilename(fileFilter:="Microsoft Excel File (*.xls), *.xls")
If Fs = "False" Then Exit Sub
ThisWorkbook.SaveAs Fs
End If

End Sub

Cory

Posted by KLove on August 01, 2001 5:23 PM

Cory:
Thank You so Much!! You made it happen.