ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Excel 2002 Automatic Macros (https://www.excelbanter.com/excel-programming/271857-excel-2002-automatic-macros.html)

CM[_4_]

Excel 2002 Automatic Macros
 
Is there a way to have a macro run automatically when a
workbook is opened, or is such a feature unavailable for
security reasons?

Thanks,

CM

Rohit Thomas

Excel 2002 Automatic Macros
 
Here's a response from John Wilson in an earlier post
today:

Two ways.....

Sub Auto_Open()
'your code here or your sub name here
End Sub

or place your code (or a call to your sub) in the
Workbook_Open Event
Double click on the "ThisWorkbook" in the "Projects"
window and copy
and paste the following:

Private Sub Workbook_Open()
'your code here or your sub name here
End Sub

-----Original Message-----
Is there a way to have a macro run automatically when a
workbook is opened, or is such a feature unavailable for
security reasons?

Thanks,

CM
.



All times are GMT +1. The time now is 12:09 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com