Skip to content
Release: Australia · Updated: 2026-03-12 · Official documentation · View source

Use the screen or element match rules

Use the screen or element match rules to match a screen or element from among multiple screens and elements with its corresponding rules. Match rules enables the connector to identify the appropriate screen or element and perform tasks.

Before you begin

Capture at least one emulator screen and an element.

Role required: none

About this task

To perform tasks on a specific emulator screen or element from among multiple emulator screens and elements, the Terminal connector must first identify a screen. To identify a screen or element, the Terminal connector uses the screen match rules, attributes, and the element locators. The screen match rules, locators, and attributes provide unique identification criteria for each screen and element.

All captured screens have a default screen match rule. Additionally, you can define one or more screen match rules. You can modify or remove the default screen match rules or the screen match rules that you define.

Screen and elements have different match rules. For a screen, the terminal connector uses screen match rules and for an element, it uses locators.

Image omitted: terminal-connector-screen-rules.png
Default screen match rule and the option to define a screen match rule.

The image shows the locators for a screen element.

Image omitted: terminal-connector-locators.png
Field or table locators.

Procedure

  1. Rename the screen with a unique name.

    1. Under the Screen and elements pane, select the screen.

    2. Under the Properties pane, rename the screen and press Enter.

Image omitted: terminal-connector-rename-screen.png
Update screen name.
    The new screen name appears under the Screen and elements pane.

3.  Under the Screen and elements pane, right-click the screen and select **Refresh**.

    If the screen match rule matches a screen, the screen match icon \(
Image omitted: screen-match-icon.png
Screen match icon\) appears for both the screen and the screen match rule. The icon indicates that the screen match rule matches with the screen.
Image omitted: terminal-connector-rule-matched.png
Screen rule match.
  1. Define a screen match rule.

    You can add a field or text from the emulator screen that the Terminal connector uses as a screen match rule.

    1. Select Add.
Image omitted: terminal-connector-add-screen-rule.png
Screen rule add button.
2.  Right-click on the required field and select either of the options.

    -   **Add this Field as screen match rule**: The connector uses the field details such as row, column, and text as a screen match rule.
    -   **Add this Text as screen match rule**: The connector uses the field text as a screen match rule.
Image omitted: terminal-connector-add-screen-rule-options.png
New screen rule options.
    The screen match rule appears under the **Screen match rules** pane.

3.  Select **OK**.
  1. Define an element and match rules.

    The Terminal connector provides multiple rules or locators that provide information about elements. For example, the row and column numbers of the field on the screen is one of the match rules. The Terminal connector provides five locators and you can choose any locator to match the element.

    1. Rename the field.

      When you capture multiple elements, the Terminal connector provides them default names such as Field_0, Field_1, Table_0, and Table_1. To easily identify an element, you can rename it.

Image omitted: terminal-connector-update-element-name.png
Update default element name.
    The updated element name appears under the Screens and elements pane.
Image omitted: terminal-connector-new-element-name.png
New element name.
2.  Right-click the element and select **Refresh**.

    The element match icon \(
Image omitted: screen-match-icon.png
Screen match icon\) appears for the element. The icon indicates that the locator matched with the element.
Image omitted: terminal-connector-default-element-rule.png
Default element match rule.
3.  Use the other locators in the **Locator** drop-down to match the element.

    The table describes the locators.
RuleDescription
Field By PositionMatches a field with its row and column number in the screen. The Row and Column fields show the row and column numbers of the starting point of the field that you captured from the screen.
Image omitted: terminal-conn-locator-one.png
Row and column number of a field.
Field By IndexMatches a field with its index number in the screen.An index number is a unique identifier of a field in the Mainframe screen that enables the connector to identify a field. Each field on the emulator screen has a unique index number. The first field in the first row gets index 1, then the second field in the first row gets index 2, and so on. Index numbers are first assigned to the fields in the first row and then from the first field of the second row until all fields in the screen get index numbers.
Image omitted: terminal-conn-index.png
Field indexes.
Field By Previous Field Text

Matches a captured field with the text in the field that is located immediately before the field that you captured. The Previous Field Text match rule shows the text in the previous field.

Image omitted: terminal-conn-locator1.png
Field By Previous Field Text.</p>

Image omitted: terminal-conn-previous-field-text.png
Previous Field text.</p>

If there is no previous field, the Previous Field Text field shows no value.

Field By Next Field Text

Matches a field with the text in the field that is located immediately after the field that you captured. The Next Field Text match rule shows the text in the next field.

Image omitted: terminal-conn-locator2.png
Field By Next Field Text.</p>

Image omitted: terminal-conn-next-field-text.png
Next Field text.</p>

If there’s no next field, the Next Field Text field shows no value.

Region \(Table\)Use this locator when you want to capture data from an emulator screen in the tabular format. The image shows the selected the fields with data in a tabular format.
Image omitted: terminal-conn-table-region.png
Region in a screen.
  1. Define an attribute and match rules.

    1. Select the field.

      The field attribute appears under the Match attributes pane.

Image omitted: terminal-connector-element-attribute.png
Element attribute.
2.  Select the attribute.

3.  Right-click the element and select **Refresh**.

    The element match icon \(
Image omitted: screen-match-icon.png
Screen match icon\) appears for the element and the attribute. The icon indicates that the attribute matches with the element.
Image omitted: terminal-connector-attribute-refresh.png
Attribute refresh.
  1. Modify screen match rules.

    1. In the screen match rules section, select the rule.

      The Properties pane shows the match rule details.

Image omitted: terminal-conn-match-rule-details.png
Match rule details.
2.  In the Properties pane, select the expand match rule icon \(
Image omitted: match-rule-icon.png
Match rule icon.\)
3.  Update the values in the **Comparison Type** or **Comparison Value** fields.

4.  Clear the **Enabled** option.
Image omitted: terminal-conn-match-rules-update.png
Match rules update options.
5.  Select **Done**.
  1. Modify a field match rule.

    1. Under the Screens and elements pane, select the required field that you captured.

      The Match attributes pane shows the field attributes.

Image omitted: terminal-connector-field-attributes.png
Field attributes.
2.  In the Properties pane, select the expand match rule icon \(
Image omitted: match-rule-icon.png
Match rule icon.\)
3.  Update the values in the **Comparison Type** or **Comparison Value** fields.

4.  Clear the **Enabled** option.
Image omitted: terminal-connector-field-match-rule-update.png
Field match rules.
  1. To match both the screen and its elements with the corresponding rules, locators, or attributes at once, right-click the screen and select Refresh screen and elements.
Image omitted: terminal-connector-match-screen-element.png
Match screen and element.
The element match icon \(
Image omitted: screen-match-icon.png
Screen match icon\) appears for the screen and its elements and the corresponding rules, locators, or attributes.
Image omitted: terminal-connector-match-all.png
Screen and element match.

Parent Topic:Configure the Terminal connector