Enter Event property

Official Content
This documentation is valid for:

In Smart Devices applications, there are several cases in which an action is performed when the user taps on the Return (virtual) key while positioned on a certain field.

Typical examples

  • In a Login dialog box, after entering the password we want the login to be executed upon tapping on Return in the password field.
  • In a dialog box we have a text field; after entering the text to search, we want the search to run by pressing Enter.

The Enter Event property indicates what action to take upon pressing the Return (virtual) key while being positioned on the control. It is applied to controls associated with Attributes, Variables and SDT elements.

Values

The possible values are as follows:

Platform Default It’s the default value. In Android, it’s the equivalent to <Go To Next Field> and in iOS to <None>.
Go To Next Field It takes the user to the next field that accepts data input.
If the control is the last one on the screen (lower right section), it doesn’t take the focus to the first field of the form nor executes any event in particular (Save, for instance).
None Focus is simply lost from the field that accepted the data.
Event Name It allows selecting the name of an existing event or creating a new one.

How do we change the text displayed on the virtual keyboard?

Since devices, in general, have a virtual keyboard, we want the Return or Enter key to show a different label depending on the action to be performed. To this end, the Enter Key Caption property is provided in Attributes and Variables and it's translated according to the language of the device.

The Enter Key Caption property is enabled only when selecting an event to run.

Enter Key Caption has the following possible values:

  • Default
  • Go
  • Search
  • Send
  • Join (iOS only)

This property only changes the label of the virtual keyboard's return key.

Scope

Applies to: Native Mobile Generator

Constraints

  • It doesn’t work in multiline fields (LongVarChar or controls with Auto Grow property set to True, for instance). In general, here the Return (virtual) key inserts a new line.
  • In iOS, it doesn’t work in numeric fields because the virtual keyboard doesn’t have a confirmation key.
  • In general, it works for edit fields; the enter event will be supported depending on each user control.