Terminal Exception occurs very often when we reduce the DelayMS propery value in terminal activities

Scenario: I am using UiPath Terminal automation to connect to AS400 iSeries machine that runs an insurance core application. I use IBM Personal communications provider to connect to the terminal. The problem I face is when we try to increase the speed of navigation / data entry by reducing the DelayMS property (300 default value for many activities) the terminal session throws unexpected errors randomly.

My requirement is an approval process with thousands of transactions in an excel file to approve them. The robot need to be very fast due to the high volume expected. But in UiPath, we are not able achive the speed we want because the robot terminates for every 5 or 10 records and shows “Terminal Exception”. The same code, when we increase the DelayMS propery to 1000, then the robot executes with out any error/interruption irrespective of number of records. In this case it takes about 36 to 40 seconds to approve one record. that means it takes 10 hours to approve 1000 records which is not acceptable. Due to this we are forced to look at other automation options where the approval process can be done much faster.

The problem seems to be with UiPath tools terminal connection and processing ability. Is there a solution or patch available to fix this and achieve more speed? Do I have any other alternate provider that i can choose to connect to AS400 terminal so that i don’t get such errors? Any help is much appreciated.

Steps to reproduce: Create a flowchart / sequence to navigate AS400 terminal windows that performs data entry in to a screen for 50 records reading from excel. Now run the robot it will run correctly. Now inorder to increase the speed of Data entry, reduce the DelayMS default property value to 100 or less than 100. Run the process. the robot will throw terminal exception randomly.

Current Behavior:

Expected Behavior:

Studio/Robot/Orchestrator Version: 2016.1.6137

Last stable behavior: NA
Last stable version: NA
OS Version: Windows 7
Others if Relevant: (workflow, logs, .net version, service pack, etc):

Hi there,
I have only recently joined the UiPath family and I am just reading your post.
Did you get any responses/answers?

My background is with the iSeries and I am very interested.


Hi Steve,

I’m having issue with production. The robot is unable to export the report in iSeries. But in test running it in orchestrator and studio it runs successfully. I keep getting a click text error. Do you have any setting suggestions I can make in iSeries for the robot to interact? I already have java bridge installed and java updated. I’d appreciate any feedback you might have.

Raw message: Object

message: Error :- #Message :-Text was not found #Source:- UiPath.UiAutomation.Activities #Stacktrace :- at UiPath.Core.Activities.ScopeActivity.OnFaulted(NativeActivityFaultContext faultContext, Exception propagatedException, ActivityInstance propagatedFrom) at System.Activities.Runtime.FaultCallbackWrapper.Invoke(NativeActivityFaultContext faultContext, Exception propagatedException, ActivityInstance propagatedFrom) at System.Activities.Runtime.FaultCallbackWrapper.FaultWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)

Hi April,
I cannot give any advice from a UI perpspective (I am such a newbie) however from an iSeries one, authorities can really stop you in your tracks.

The clue is, it runs in “test”. Fantastic. I would try and work out the differences between the test and production environments. You really need to get the advice from who is looking after this. It may be the user profile used. The way the libraries are setup. The authority on the files/objects you want to access.

Not the answer you were wanting, I hope this will help, steer you in a good direction.



DelayMS is there to ensure the screen is ready by the time the next activity is executed, if the terminal screen is not ready and 2 subsequent activities are not in sync with terminal’s emulator lag, you will get errors.

The typical issue appears when you use AID keys and screen travels back to host for processing and then sends the next one to the terminal. Until the next screen is displayed and ready for input, the screen is keylocked (meaning any input you’ll send to it it will error out).

Now this requires a bit of attention and careful consideration of the app you’re automating and on screen transitions use the “Wait Screen Text” activity to detect the moment the second screen of a screen transition got displayed. This will cancel the need of DelayMS (in these screen transitions).

So the above are generic advises. As you can imagine, the connection method counts as well for more details. With IBM Personal Communications there are 3 different methods to connect. Feel free to explore them, but regardless of the method used, do not handle DelayMS globally (from your text I have the impression that that is what you’re trying and I can understand the issues if it’s handled that way) - address screen transitions with Wait Screen Text (and cancel DelayMS in those), test low DelayMS values for other interactions (that do not cause screen changes (or key locks in the terminal emulator app).

@april_patriarca , when it comes to Terminals, please use TAB and Shift + TAB to navigate in the screen rather than clicks.