Test Container Automation scripts can contain functions that
handle events generated by controls on the form.
Any VBScript Sub whose name is of the form controlname_eventname
will automatically handle the eventname event of
controlname control. This automatic association is
created when the script is loaded. This means that any controls for which the
script has event handlers must already exist on the form with the proper name
when the script is loaded.
The easiest way to do this is to place all of the desired controls on the form,
set each control’s name using the Extended page on its property sheet, and then
load the script that contains the event handlers. To avoid repeating these
steps, you can then save the session to a file. Loading a session loads all of
the controls on the form, and then loads all of the scripts that were saved in
that session.