Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks Jake,
Your explanation has been most helpful. RichardG "Jake Marx" wrote in message ... Hi RichardG, RichardG wrote: In doing a word search on "ThisWorkbook" in this newsgroup's archives, there was a lot of discussion on what to put into this module. What I wanted to know is, what is the advantage of using this module verses a general module or the worksheet module; and what is the purpose for this module? The ThisWorkbook module is a class module that contains the events subroutines that are raised due to certain Workbook-related events. For example, the Workbook_Open event routine will be executed when the Workbook is opened. The Workbook_SheetActivate event routine will be executed when the user (or code) activates a new Worksheet within the Workbook. So, code related to the Workbook events should be placed in the ThisWorkbook module. The various Worksheet modules are used for Worksheet-related events (such as Change and SelectionChange), and standard modules should be used for your VBA functions and subroutines. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Compile error in hidden module: ThisWorkbook | New Users to Excel | |||
Compile error in hidden module: ThisWorkbook | Setting up and Configuration of Excel | |||
Workbook_Open in ThisWorkbook.module | Excel Discussion (Misc queries) | |||
Compile error in hidden module: ThisWorkbook | Excel Discussion (Misc queries) | |||
ThisWorkbook module question | Excel Programming |