I am trying to create a command button that is attached to a macro that will allow the user to save the worksheet that prompts the user for a specified file name. Or automatically save the worksheet as a field name title. Currently this is the code I have:
Private Sub SaveButton_Click()
ActiveWorkbook.SaveAs Filename:= _
"C:\Documents and Settings\MYoung\Desktop\h&h VALVE\" & Range("Company:"), _
FileFormat:=xlNormal, Password:="", WriteResPassword:="", _
ReadOnlyRecommended:=False, CreateBackup:=False
End Sub
or
Sub Save()
ActiveWorkbook.SaveAs Filename:= _
"C:\Documents and Settings\MYoung\Desktop\h&h VALVE\" & Range("Company:"), _
FileFormat:=xlNormal, Password:="", WriteResPassword:="", _
ReadOnlyRecommended:=False, CreateBackup:=False
End Sub
the top is code I just applied to the command button to try it, and the bottom is the code for the macro.
I would appreciate any help I can get on this. Thank you in advance.
Bookmarks