Adding shortcut keys to harness buttons
Summary
To speed user input, developers can define a keyboard shortcut for buttons on a work object form, as defined by harness rules.
This is an optional capability available in all applications, and is recommended for accessible applications.
Suggested Approach
For a new button
To create a new button with a shortcut key:
- In the Layout tab of the Harness rule form, select the button icon from the Basic drop down group and drag it to the harness.
- Click the magnifying lens icon. The Button properties panel displays.
- On the Button tab, select the type of button from the drop down list and input the tooltip to display when hovering over the button. In the caption field, add an ampersand '&' to the button caption.
The ampersand '&' can be located anywhere in the button caption. The letter following the ampersand '&' will become the shortcut key for the button.
- Click OK and save the Harness form.
For an existing button
To add a shortcut key to an existing button:
- In the harness rule, select an existing button and click the magnifying lens icon. The Button properties panel displays.
- On the Button tab, in the caption field, add an ampersand '&' to the button caption.
The ampersand '&' can be located anywhere in the button caption. The letter following the ampersand '&' will become the shortcut key for the button.
- Click OK and save the Harness form.
Using a shortcut key
To use a custom-defined shortcut key for a button, hold the Alt button while pressing the appropriate key. For instance, if you defined a shortcut key for a create button with ampersand '&' located before the 'c' in create, you would press ALT+C in order to activate the create button.