A VBA (Visual Basic for Applications) module can implement an initializing function which will be executed by RC-WinTrans each time the VBA project (the macros file) is initialized to be used in the VBA system. This is typically at the time when RC-WinTrans is started up. The function is also called when the corresponding macros file is added to RC-WinTrans using the Add Macros File command.
A terminating procedure can be implemented to supplement the initializing function.
NOTE: When you create a new macros file you can opt to create it with a module in which a macro-initializing and a macro-finalizing function are already implemented.
Initializing a module is useful for enabling, creating, or loading something to make it available immediately after RC-WinTrans is started.
Some examples of how an initializing function can be used include:
NOTE: Each module can implement an initializing function (one time). The function will be called for each module.
This function is called after RC-WinTrans has been started and the VBA system is running.
This procedure is called before RC-WinTrans is closed or when a macros file is going to be removed from the VBA system.
NOTE: An "OnTerminateModule" procedure can be implemented for each module.
For a sample implementation of a module-initializing function and a supporting terminating procedure used to create a new macros file with RC-WinTrans, open the Macros Files dialog box (Tools menu | Macros Files command) and select the template file "With module initializing procedures."
|