Show TOC

Procedure documentationProcessing an Action Locate this document in the navigation structure

 

You can perform the following operations for the action that you created in the Mobile Project:

  • Assign the action to the event of a UI element

  • Implement the action event handler, as required

The mobile client for laptops executes the action event handler at runtime when the application user triggers the action by using the associated UI element.

Prerequisites

You have created the required actions and UI elements in the Mobile Project.

Procedure

Assigning an Action to the Event of a UI Element
  1. In the Laptop UI explorer, double-click the view element in which you want to implement the action.

  2. Choose the Layout

  3. In the Outline View, click the required UI element.

  4. Choose the Properties tab.

  5. Under Event, click onAction.

  6. Select the required action from the dropdown list box.

  7. Choose   File   Save  .

Implementing the Action
  1. To view the generated source code for the event handler onAction <Name of Action>,click the required view element with the secondary mouse button, and choose   Open   Open Java Editor  .

The program code of the event handler should only be inserted into the code area, as shown below, otherwise the IDE overwrites or deletes the code during code generation:

Comment lines //@@begin

Code area

...

Code area

Comment lines //@@end

  1. Program the event handler, as required.

  2. Choose   File   Save  .