Automatic Macros
Hey! I need some help form the pros, I need to create a
macro that runs automatically when the workbook in excel opens, How do I do that? Thanks |
Automatic Macros
Use the Workbook_Open event of your workbook.
ex: In your workbook VBA module Private Sub Workbook_Open() msgbox "Workbook Open!!!!!" end sub -----Original Message----- Hey! I need some help form the pros, I need to create a macro that runs automatically when the workbook in excel opens, How do I do that? Thanks . |
Automatic Macros
Diego,
You can name the macro Auto_Open. Alternatively, you can use the Open event of the workbook. In the ThisWorkbook code module, use Private Sub Workbook_Open() ' your code here End Sub -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "Diego" wrote in message ... Hey! I need some help form the pros, I need to create a macro that runs automatically when the workbook in excel opens, How do I do that? Thanks |
Automatic Macros
Thanks!!!! I tried naming it auto_open it worked. By the
way...How do I get to the this workbook code module? I couldn't do it. Regards. -----Original Message----- Diego, You can name the macro Auto_Open. Alternatively, you can use the Open event of the workbook. In the ThisWorkbook code module, use Private Sub Workbook_Open() ' your code here End Sub -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "Diego" wrote in message ... Hey! I need some help form the pros, I need to create a macro that runs automatically when the workbook in excel opens, How do I do that? Thanks . |
All times are GMT +1. The time now is 04:34 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com