Hi All,
I'm have a few issues, I'm attempting to set up a vba code that links to a "save" button in my excel workbook.
My original file is located in Drive H:\ but I want the vba code to open the save as dialog box (which it does) but I'm wanting it to default to G:\Community\Assessments\
Unfortunately the below code is not accessing the default drive/folder that I'm wanting to save in, and it is also coming up with a Run-time error '1004' Method 'SaveAs' of object'_Workbook' failed.
I want to also ensure that the saved files save as .xlsm files.
I have the following code (in Module3);
Sub SaveAs()
ActiveSheet.Unprotect Password:="Password"
Application.Dialogs(xlDialogSaveAs).Show
ActiveWorkbook.SaveAs Filename:=("G:\Community\Assessments\")
ActiveSheet.Protect
End Sub
Any assistance on this is greatly appreciated, I have been trying to get this to work all day without success.
Thanks
I'm have a few issues, I'm attempting to set up a vba code that links to a "save" button in my excel workbook.
My original file is located in Drive H:\ but I want the vba code to open the save as dialog box (which it does) but I'm wanting it to default to G:\Community\Assessments\
Unfortunately the below code is not accessing the default drive/folder that I'm wanting to save in, and it is also coming up with a Run-time error '1004' Method 'SaveAs' of object'_Workbook' failed.
I want to also ensure that the saved files save as .xlsm files.
I have the following code (in Module3);
Sub SaveAs()
ActiveSheet.Unprotect Password:="Password"
Application.Dialogs(xlDialogSaveAs).Show
ActiveWorkbook.SaveAs Filename:=("G:\Community\Assessments\")
ActiveSheet.Protect
End Sub
Any assistance on this is greatly appreciated, I have been trying to get this to work all day without success.
Thanks