Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
How can I rename a macro in Excel 2000 to run automatically when the
spreadsheet opens? Thanks, Mike |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Mike, you can name it auto_open or put your code in the workbook open event
Sub Auto_Open() 'your code here End Sub or in thisworkbook Private Sub Workbook_Open() 'your code here End Sub -- Paul B Always backup your data before trying something new Please post any response to the newsgroups so others can benefit from it Feedback on answers is always appreciated! Using Excel 2000 & 2003 ** remove news from my email address to reply by email ** "OceansideDJ" wrote in message ... How can I rename a macro in Excel 2000 to run automatically when the spreadsheet opens? Thanks, Mike |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Use the Workbooks_Open event and call you macro from there. This sub should
be put in the ThisWorkbook module (select it from the dropdowns at the top of the module to insure it is declared properly. See Chip Pearson's page on Events: http://www.cpearson.com/excel/events.htm -- Regards, Tom Ogilvy "OceansideDJ" wrote in message ... How can I rename a macro in Excel 2000 to run automatically when the spreadsheet opens? Thanks, Mike |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You need to add this event code plus you macro code to the this Workbook
module of your worksheet. Private Sub Workbook_Open() 'Your code here End Sub "OceansideDJ" wrote: How can I rename a macro in Excel 2000 to run automatically when the spreadsheet opens? Thanks, Mike |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Mike,
In a standard module, try this... Sub Auto_Open() .... End Sub OR In the "ThisWorkbook" module... Private Sub Workbook_Open() .... End Sub Dale "OceansideDJ" wrote: How can I rename a macro in Excel 2000 to run automatically when the spreadsheet opens? Thanks, Mike |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Auto Calculate Question / HELP! | Excel Worksheet Functions | |||
Auto filter question | Excel Worksheet Functions | |||
Macro Help Needed - Excel 2007 - Print Macro with Auto Sort | Excel Worksheet Functions | |||
auto filling question | Excel Discussion (Misc queries) | |||
auto filter question | Excel Programming |