Pop-Up Window - Mystery

I have an RPA project in IE browser that involves pop-up windows. The Pop-up windows and the control-back to the main windows take time sometimes. So I have used “On Element Appear” with the RepeatForever as False and WaitVisible checked.

The automation works just fine when I run it in the studio and in the Orchestrator when I watch it. But when I am not watching it (while running from the Orchestrator), the program fails at the “On Element Appear” with a time out!

What could be the reason?
What is the best way to have the program wait when control switches between the main window and pop up windows or when the page has to be fully loaded when clicking a save\update in a Webpage?

Hi @Devarajan_Sundaresan

What have you set for the property wait for ready in the on element appear activity? Try changing that to see whether it helps. Also, default timeout period is 30 seconds. If you think it is taking more time to switch between the windows, try increasing that time as well and see whether it works

@Lahiru.Fernando Thanks. The Wait for “Ready is set” to Interactive. The windows are coming quick enough so I do not think its that’s the problem.

Every time I run it through studio and watch it, it works fine. When run from Orchestrator, it fails 99/100 times!

By the way my selector in the On Element appear is as below. Its the whole pop up window. selector

I monitored the Robot again today and it just worked fine when I watched it. But it was failing all the while when not monitored failing with time out at the ‘On element appear’.

As a work around, I removed the ‘On element appear’.and added a 5 sec delay before that.

Something is wrong with the ‘On element appear’ or my understanding with it! Please suggest which one.

If this popup is always supposed to appear at a certain step of your flow, then i would not use On Element Appears, just go with maybe a try catch and the popup selector with a timeout and do something in the catch if it dont work…

Update: The issue does not seem to be with the ‘On element appear’ rather its with the control not flowing to the pop-up window. I removed the ‘On element appear’ and the reslut is the same. So I updated this topic header too.

Still the mystery is - everything works fine when run from Studio or when the robot is monitored. But fails every time when unattended.

maybe you are using some activity that does not work on the background. If i may know, how do you monitor the process running in a server without disrupting the robot itself?

@bcorrea I just logged in to the server and do nothing but just see when the Robot runs.

It was just a type in to activity.

By the way, there isn’t anyway to make this work!?! :frowning:

in my experience if i log in while the robot is running, that causes the robot’s session to break… i would have to tell you to look the properties of your activities to see if you need to change anything to be able to work on the background.

Let me see. It was just a ’ Type In to’ activity.

I have tried an ‘on element appear’ and a ‘click’ before that ‘type in to’. Whatever may be activity first in the pop-up window, it times out. I feel somehow the control is not flowing to the pop-up. the selector for the pop up is simple. I even tried an attach window to see if that helps.

Suggestions welcome

did you see my suggestion from 5 hours back?

@bcorrea yes, I did. Thanks.

The pop-up in my workflow appears always and it appears when the robot clicks a lens in the web page.
The pop up provides a key information back to the web page. It fails every single time when the robot runs it from the orchestrator. I’m not sure want to do with the try catch here as it fails every single time. The pop up had to work for me for the workflow to proceed.

I mean you could remove on element appears and change to try catch, inside it you do the actions on the popup that you need putting the proper timeout on the first activity, this should work normally as long as the popup does appear… on the catch you put a capture screenshot so you can be sure that if fails is not because that popup isn’t showing up on the background…