Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Auto-run macro after a save-as event
Hi,
I am trying to auto run a macro after I save a workbook. I'm picking u where someone else is left off so I'm having some trouble following I'll describe the situation and if you have a better sugguest, pleas let me know. All help is appreciated! There is an existing VB project that does a certain action. It wil write data to an Excel spreadsheet and save it as a .xls. What I wan to do is do some post-saving actions with a macro that I have alread written in VBA. I know that there's a auto_open that automatically open macro's upo opening of a file. Is there any auto_?? that could detect the savin of a file and run the macro specified? Since I already developed the macro in VBA and it uses a lot of cel references to the Excel spreadsheet, I want to link the VB applicatio with excel. I want to have a template Excel file whch already contain the VBA macro, have the VB application write to the template file, sav the file as something else and run the VBA macro contained. Or is it better to have the module imported to the excel spreadshee automatically and run that after the save command in the VB script? Thank you very very much -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Auto-run macro after a save-as event
Hi
look at the workbook event BeforeSave for this -- Regards Frank Kabel Frankfurt, Germany Hi, I am trying to auto run a macro after I save a workbook. I'm picking up where someone else is left off so I'm having some trouble following. I'll describe the situation and if you have a better sugguest, please let me know. All help is appreciated! There is an existing VB project that does a certain action. It will write data to an Excel spreadsheet and save it as a .xls. What I want to do is do some post-saving actions with a macro that I have already written in VBA. I know that there's a auto_open that automatically open macro's upon opening of a file. Is there any auto_?? that could detect the saving of a file and run the macro specified? Since I already developed the macro in VBA and it uses a lot of cell references to the Excel spreadsheet, I want to link the VB application with excel. I want to have a template Excel file whch already contains the VBA macro, have the VB application write to the template file, save the file as something else and run the VBA macro contained. Or is it better to have the module imported to the excel spreadsheet automatically and run that after the save command in the VB script? Thank you very very much! --- Message posted from http://www.ExcelForum.com/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Macro to auto save file using the format YYMM | Excel Discussion (Misc queries) | |||
save as event | Excel Programming | |||
Macro vs Manual save event | Excel Programming | |||
auto save as macro | Excel Programming | |||
After save event | Excel Programming |