Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
macro
looking for the command to automate a macro to run on
worksheet open and on close |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
macro
If you call your macro from the Workbook_Open() event it will fire
when the workbook opens: Private Sub Workbook_Open() MyMacro End Sub This needs to be put in the ThisWorkbook code module, with MyMacro in a regular code module. To fire before close (also in the ThisWorkbook code module): Private Sub Workbook_BeforeClose(Cancel As Boolean) MyOtherMacro End Sub In article , "George Hanna" wrote: looking for the command to automate a macro to run on worksheet open and on close |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Macro recorded... tabs & file names changed, macro hangs | Excel Worksheet Functions | |||
need help to update macro to office 2007 macro enabled workbook | Excel Discussion (Misc queries) | |||
Macro Help Needed - Excel 2007 - Print Macro with Auto Sort | Excel Worksheet Functions | |||
using a cell value to control a counter inside a macro and displaying macro value | Excel Worksheet Functions |