Run a Macro at Startup

  • Thread starter Thread starter Dennis
  • Start date Start date
D

Dennis

I would like a macro that I have to run when I open the Workbook. Is there a
wat to do this?

Dennis
-==========
 
Dennis,

Either name the macro Auto_Open and put it in a normal code module (old way)
or put it in Worksheet_Open event code in ThisWorkbook code module (new
way).


--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
Bob Phillips said:
Dennis,

Either name the macro Auto_Open and put it in a normal code module (old way)
or put it in Worksheet_Open event code in ThisWorkbook code module (new
way).

Sorry to be pedantic Bob, but do you mean Workbook_Open?
 
1. Alt-F11 to access VBE.
2. Ctrl-R to activate Project Explorer.
3. Select your Project.
4. Select Microsoft Excel Objects
5. DoubleClick This WorkBook
6. Select WorkBook in left DropDown.
7. Select Open in right DropDown.

See the following links on Events.

http://www.mvps.org/dmcritchie/excel/event.htm
http://www.cpearson.com/excel/events.htm

http://support.microsoft.com/default.aspx?scid=kb;en-us;213220&Product=xlw
http://support.microsoft.com/default.aspx?scid=kb;EN-US;291294
http://support.microsoft.com/default.aspx?scid=kb;EN-US;161761

HTH
Paul
 
Back
Top