You can use a wizard to generate the code for a self-installing plug-in that contains a custom event. In addition to generating the skeleton code for the plug-in and the event, the wizard can also generate the code required to add the event to a menu.
To create a self-installing event
Click FilePlug-ins to open the Plug-in Manager.
Tip In the Tools Development Environment layout, click the Plug-ins tab to switch to the Plug-in Manager view.
In the Script Language list, click the language you want to generate.
On the Event Definition tab, select the check boxes for the events you want to handle.
The wizard generates an OnEvent callback for each event you select. The User Event Name is used to name the callback function. For example, the default name for an OnEvent callback for an siOnSelectionChange event is "siOnSelectionChangeEvent_OnEvent".
The first character in the user event name should be a letter. Subsequent characters can be letters, numbers, or underscore (_) characters.