ExcelBanter

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

rmcsantos

Automatic Macros
 
In previous version of Excel, we can use sub autopen or sub autoexec, or
something like that~.
Now in Excel 2003 can we use the same sub? Or there is anyway to do it?

Thanks

--
Rui Santos
Portugal

Charles Chickering

Automatic Macros
 
Sub AutoOpen() Still works, how ever there are a lot of event driven options
available in the current version of excel. Open the Editor, then double click
the "ThisWorkbook" item under the VBAProject(YourBook.xls) on the left side
of the screen. then above the code window there should be 2 comboboxex, in
the left one select "Workbook" in the right one there should be a list of all
the event triggers that you can use, select the one that's most appropriate
for what you want to do, probably Open.

HTH
--
Charles Chickering

"A good example is twice the value of good advice."


"rmcsantos" wrote:

In previous version of Excel, we can use sub autopen or sub autoexec, or
something like that~.
Now in Excel 2003 can we use the same sub? Or there is anyway to do it?

Thanks

--
Rui Santos
Portugal


Dave Peterson

Automatic Macros
 
But use:
Sub Auto_Open()
(note the underscore)

rmcsantos wrote:

In previous version of Excel, we can use sub autopen or sub autoexec, or
something like that~.
Now in Excel 2003 can we use the same sub? Or there is anyway to do it?

Thanks

--
Rui Santos
Portugal


--

Dave Peterson

Charles Chickering

Automatic Macros
 
Doh! Thanks, for catching my typo Dave.
--
Charles Chickering

"A good example is twice the value of good advice."


"Dave Peterson" wrote:

But use:
Sub Auto_Open()
(note the underscore)

rmcsantos wrote:

In previous version of Excel, we can use sub autopen or sub autoexec, or
something like that~.
Now in Excel 2003 can we use the same sub? Or there is anyway to do it?

Thanks

--
Rui Santos
Portugal


--

Dave Peterson



All times are GMT +1. The time now is 11:38 AM.

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