Determines whether Enter simulates Tab in a form.

Syntax

SET CUAENTER ON | off

Default

The default for SET CUAENTER is ON. To change the default, update the CUAENTER setting in PLUS.ini. To do so, either use the SET command to specify the setting interactively, or enter the CUAENTER parameter directly in PLUS.ini.

Description

The CUA (Common User Access) interface standard dictates that the Tab key moves focus from one control to another, while the Enter key submits the entire form (which fires the form’s onSelection event). Use SET CUAENTER to control whether Enter follows the CUA standard. If SET CUAENTER is OFF, the Enter key emulates the Tab key, moving the focus to the next control. This behavior is important to note in the case of dialog boxes, where either the OK or Cancel button is specified as the default (See the PushButton's default property). When CUAENTER is set to OFF, pressing the Enter key will cause focus to toggle between these buttons, thus preventing the form from being submitted.

There are two good reasons to ignore the CUA behavior:

In many forms, especially ones that take advantage of the numeric keypad, using the Enter key to move to the next control speeds data entry.

For non-trivial forms, there are usually a number of pushbuttons which take completely different actions; for example, adding a new record, deleting the current record, navigating forward, navigating backward, etc. If you press Enter while the focus is in an entryfield for example, the act of submitting the form tells you nothing about what the user wants to do next.

In fact, few applications consider the action of submitting the form; the onSelection event is rarely used. When the onSelection event is left undefined, nothing happens when you press Enter (except in a control like the Editor). So you might as well make the Enter key do something useful and have it move the focus to the next control.

Regardless of the setting of SET CUAENTER, you can move focus from object to object with the mouse or by pressing Tab and Shift-Tab.