ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   How to run an excel Macro in VB? (https://www.excelbanter.com/excel-programming/307120-how-run-excel-macro-vbulletin.html)

Jonx

How to run an excel Macro in VB?
 
Hello everyone, I have a macro already defined in an excel workbook. I
other words, if I open the workbook, and push alt+F8, it wil
automatically run the macro, I was curious how I would run this in VB?
I am creating a program in VB that populates the cells in the workboo
and then runs the script.

Help?

Thank

--
Message posted from http://www.ExcelForum.com


Tom Ogilvy

How to run an excel Macro in VB?
 
oxlApp.Run "Myworkbooks.xls!Macro1",arg1

--
Regards,
Tom Ogilvy

"Jonx " wrote in message
...
Hello everyone, I have a macro already defined in an excel workbook. In
other words, if I open the workbook, and push alt+F8, it will
automatically run the macro, I was curious how I would run this in VB?
I am creating a program in VB that populates the cells in the workbook
and then runs the script.

Help?

Thanks


---
Message posted from http://www.ExcelForum.com/




Frank Kabel

How to run an excel Macro in VB?
 
Hi
you may put your macro code in the workbook_open event. This way it
will automatically run at startup

--
Regards
Frank Kabel
Frankfurt, Germany

"Jonx " schrieb im Newsbeitrag
...
Hello everyone, I have a macro already defined in an excel workbook.

In
other words, if I open the workbook, and push alt+F8, it will
automatically run the macro, I was curious how I would run this in

VB?
I am creating a program in VB that populates the cells in the

workbook
and then runs the script.

Help?

Thanks


---
Message posted from http://www.ExcelForum.com/



Jonx[_3_]

How to run an excel Macro in VB?
 
Thanks for the help, I appreciate it a lo

--
Message posted from http://www.ExcelForum.com



All times are GMT +1. The time now is 03:44 AM.

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