Soniya said:
What diffetrecnce it makes a code under Workbook Open or
under Aut
![Er... what? o_O o_O](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
pen
From a coding standpoint it really doesn't make any difference at all.
I'm sure you could come up with some obscure situations in which the
sequence of event firings matter (of all the procedures that run
automatically when a workbook opens, Aut
![Er... what? o_O o_O](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
pen always runs last), but I
haven't seen any that could easily be worked around.
I tend to use Aut
![Er... what? o_O o_O](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
pen simply to avoid placing any code in the code
module behind the ThisWorkbook object. Any code in this area has the
possibility of becoming corrupt. If corruption does occur in this area,
there's no way to fix it short of rebuilding the whole workbook. This
obviously doesn't apply if you're using a WithEvents class module to trap
the Workbook_Open event from some other workbook, though.
--
Rob Bovey, MCSE, MCSD, Excel MVP
Application Professionals
http://www.appspro.com/
* Please post all replies to this newsgroup *
* I delete all unsolicited e-mail responses *