run a macro when clicking on "save as"

  • Thread starter Thread starter M K W
  • Start date Start date
M

M K W

Hello,
How to run a macro when I click on Save As?
When I click on "save as" I want a macro to run, do something, then the
"save as" will take place and the save as window appears.
thanx in advance
 
In "Thisworkbook", take a look at the BeforeSave event:

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)

End Sub

--

Regards
Andy Wiggins
www.BygSoftware.com
Home of "The Excel Auditor" and "Byg Tools for VBA"
 
Before_save can be used. In case the file is saveasUi
variable will be true if you are saving it the first time
or you are doing a Save As event.

Regards
Sharad.
 
Back
Top