View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Mike Fogleman Mike Fogleman is offline
external usenet poster
 
Posts: 1,092
Default executing macros upon opening xls files

In a general module:

Sub Auto_open()
mymacroname 'change
End sub
or

Private Sub Workbook_Open()
mymacroname 'change
End Sub

This is workbook event code.
To input this code, right click on the Excel icon on the worksheet
(or next to the File menu if you maximize your workbooks),
select View Code from the menu, and paste the code

Mike F
"dr chuck" wrote in message
...
I have a macro named "x" that i want to execute automatically when file
"panel.xls" is opened. Is that possible? any suggestions on how to do it?

--
dr chuck