Event Handler Overview
Event handling allows you to use scripting to respond to a wide variety of events that components fire. This lets you configure windows that are very interactive, and are an important part of project design in the Vision module.
An event can be many things, like a mouse click, a key press, or simply a property changing. Whenever these events occur, a script can be called to "handle" the event. Different components can fire different types of events. For example, mouse events are very common and are fired by almost all components. The cellEdited event, on the other hand, is only fired by the Table component.
To configure event handlers for a component, right click on it and choose the Event Handlers... item. You can also get to this button vial the toolbar ( ) or the Component menu. Once in the event handler window, you can pick any event to handle. Each event can have its own handling logic.
All events are handled with scripting, but you frequently don't need to write the scripts by hand. This is where the Script Builders come in. For each event, you can choose a common way of handling the event. This can be a navigation action, setting a tag value, etc. To write an arbitrary script, choose the Script Editor tab.
For example, one of the most common uses of event handlers is to open a window when a button is pushed. To do this, simply select the actionPerformed event, and select the Navigation tab. Here you can simply pick the navigation action Open, and choose the window to open. If you're curious, you can peek over at the Script Editor tab to see the underlying code that makes this action tick, but you certainly don't have to.