ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Auto_Open Workbook_Open (https://www.excelbanter.com/excel-programming/344415-auto_open-workbook_open.html)

[email protected]

Auto_Open Workbook_Open
 
What is the diferent between Auto_Open and Workbook_Open, when I use
Auto_Open in a module and open the workbook with a macro the Auto_Open
is not runing, workbook_Open runs.

Regards Yngve


Bob Phillips[_6_]

Auto_Open Workbook_Open
 
That is essentially the difference.

Auto_Open is the original way of having a macro run at workbook startup, but
with the introduction of events in XL97, the Workbook_Open event was
introduced. Auto_Open is retained for compatibility.

--

HTH

RP
(remove nothere from the email address if mailing direct)


wrote in message
oups.com...
What is the diferent between Auto_Open and Workbook_Open, when I use
Auto_Open in a module and open the workbook with a macro the Auto_Open
is not runing, workbook_Open runs.

Regards Yngve




Chip Pearson

Auto_Open Workbook_Open
 
They are very similar. Auto_Open is older than the Workbook_Open
event (events were added in Excel 97). One major difference is
that if a workbook is opened via VBA (as opposed to the
File..Open menu item), Auto_Open will not run, while
Workbook_Open will.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


wrote in message
oups.com...
What is the diferent between Auto_Open and Workbook_Open, when
I use
Auto_Open in a module and open the workbook with a macro the
Auto_Open
is not runing, workbook_Open runs.

Regards Yngve




evgny[_2_]

Auto_Open Workbook_Open
 

Bob Phillips skrev:
That is essentially the difference.

Auto_Open is the original way of having a macro run at workbook startup, but
with the introduction of events in XL97, the Workbook_Open event was
introduced. Auto_Open is retained for compatibility.

--

HTH

RP
(remove nothere from the email address if mailing direct)


wrote in message
oups.com...
What is the diferent between Auto_Open and Workbook_Open, when I use
Auto_Open in a module and open the workbook with a macro the Auto_Open
is not runing, workbook_Open runs.

Regards Yngve



evgny[_2_]

Auto_Open Workbook_Open
 
Thang`s for replying and god explanation

Regards yngve

Chip Pearson skrev:
They are very similar. Auto_Open is older than the Workbook_Open
event (events were added in Excel 97). One major difference is
that if a workbook is opened via VBA (as opposed to the
File..Open menu item), Auto_Open will not run, while
Workbook_Open will.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


wrote in message
oups.com...
What is the diferent between Auto_Open and Workbook_Open, when
I use
Auto_Open in a module and open the workbook with a macro the
Auto_Open
is not runing, workbook_Open runs.

Regards Yngve




All times are GMT +1. The time now is 07:48 AM.

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