Programming an object's properties and events

  1. Select the desired run-time platform and language, if available, from the Run menu.
  2. Select the object's property or event from the Objects tab.
  3. Type or paste code into the Script area.

Locating code within an object

To locate code within an object, click on the object in the Work pane. The pointer on the Objects tab jumps to the appropriate object. The code can be viewed by clicking the appropriate event. For example, to find code attached to a button, click the button in the Work pane, the Objects tab jumps to the button object place holder and displays the code attached to the click event. To find code attached to the onBlur event of a field, click the field in the Work pane, the Objects tab jumps to the field object place holder and displays the first coded event in the list. If the onBlur event is not the first coded event for the field object, you must click the onBlur event to display its code in the Script area.

Note: When you click from one object to another of the same type, the event selected for the first object is also selected for the second object. For example, if you click a field in the Work pane and select the Default Value event, then click a different field, the event selected for the second field is Default Value. Clicking objects of different types in the Work pane moves the Objects tab pointer to the first coded event for each object.

Color-coding event icons

All events that contain code are color-coded for the appropriate run-time platforms. An event coded to run in the Notes client displays a green icon. An event coded to run on the Web displays as a yellow icon. An event coded for both platforms displays half green and half yellow with a red dividing line down the center.

Determining the programming language at a glance

Each programming language recognized in the Programmer's pane has an icon related to it. These icons appear to the left of the object or event on the Objects tab. The following table shows the relationship of each icon to its respective programming language.

Programming language

Icon

Formula language

A diamond icon to specify a formula or simple action

JavaScript

A circle icon to specify JavaScript code

LotusScript

A scroll icon to specify LotusScript code

Simple Action(s)

A diamond icon to specify a formula or simple action

System Command(s)

A diamond icon to specify a formula or simple action