The Select action describes the use of drop-down lists in a script.
The action is defined by the following settings.
Option Indexes – The position of the selected item in the drop-down list. The index of the first option in the list is 0 (zero).
Text Values – The text of the selected item. You can use evaluation syntax in defining the text value.
Suppress firing default events – When you select this option, the events that are normally triggered by the selected list items do not occur.
Target Window – The window where the click occurs.
Locators – The elements to be clicked.
The Option Indexes field and Text Values field are used in different ways when the script is run. First, the script will try to find an option in the select box that contains the text in the Text Values field. If an option matching that criterion cannot be found, the script reverts to the specified option index. The Text Values field must be populated. If you want the script to always use the Option Indexes value, enter an arbitrary string in the Text Values field; when that string is not found, the script will use the specified position in the Option Indexes field.
Change the list selection
Change the value in the Option Indexes field to index for each item to be selected.
Change the value in the Text Values field to the text of the items to be selected.
You can specify multiple selection items by entering values separated by commas. For example, to select the second and fourth list items, enter 1,3 as the option indexes.
Suppress default events
- Select Suppress firing default events.
Change the target window setting
- Change the value in the Target Window field.
Add a locator
Click on the right side of the Locators area. A new row is added.
Select CSS or DOM from the drop-down list.
Enter the new Locator information.
Change existing locator settings
Scroll down to the Locator to change.
If necessary, change the selection — CSS or DOM — in the drop-down list.
Enter the new Locator information in the text field.
Delete a locator
- Click to the right of the Locator to delete.