Support Import

Wait for Text on Screen (OCR) Action

This action waits (pauses the execution of your script) until a specific text [2] appears/disappears [4] on the entire screen or foreground window [5] allowing you to analyze either the whole of that image or a specific subregion of it [6]. You can also specify whether you want the action to fail [7] if the text does not appear within a custom set of seconds [8]. The action returns the location [9] (coordinates) of the specified text's first occurrence (or match if a regular expression [3] is used) from left to right, top to bottom.  


wc.png OCR Engine:

This text field with drop down menu options invites you to enter or choose the instance of the OCR Engine you want to work with.

ea.png Text to Find:

This text field allows you to enter the text you want the OCR Engine to search for as text or as a Variable (please be mindful of the fact that OCR is case sensitive).

ea3.png Is Regular Expression:

Check this check box if you want to use a Regular Expression to determine the text you are looking for. A Regular Expression creates a range of possibilities and can return a number of results that may match your search. The order that the Engine is adding these matches is from top to bottom, left to right as it scans the given source to analyze.

ea4.png Wait for Text to:

This drop down menu allows you to specify whether you want to wait for the Text on screen to appear or disappear.

ea5.png Search for Text on:

Two options on this drop down menu, Entire Screen or Foreground Window only.

ea6.png Search Mode:

While the first option of this drop down menu is pretty straightforward (Search Whole Screen or Foreground Window) the other two options that allow you to target a specific subregion of your window or screen produce a whole different set of additional Properties which will see in detail here:

-Search on specified subregion of Screen or Foreground window:


By clicking the "Select a Different Subregion" button on the right of the red box, you will be prompted to select firstly the window you want to work:


and then you will be given the opportunity through an amazing interactive feature to actually select the area you want to narrow down your scan (drag your mouse to select the area). The X1 X2 Y1 Y2 co-ordinates are denoting the start and finish of your dragging maneuver.

However, using the "Select a Different Subregion" button is not compulsory. You can enter the values of the co-ordinates by hand or as a Variable (notice the Gear Icon next to the text fields).

-Subregion relative to image:


This search mode enables you to narrow down your scan through a region that is defined relative to the top-left corner of an image from the Image Repository.

ea7.png Fail if Text does not appear within:

This checkbox allows you to produce an exception (which you can in turn handle through the state of the art set of exception handling mechanismsProcessRobotis providing you with) in case the specified Text appear or does not appear within a custom set of seconds to be defined on [8].  

ea8.png Fail if Text does not appear within specified number of seconds:

The maximum number of seconds you can set in this box is 600.

ea9.png  Location of Text found:

This action returns the coordinates of the top-left corner of the text found on screen or a specified window, stored in a couple of variables for later use.