Delay Activity and Delay After/Before Within Acitivity Not Working - What should I do?

Both the Delay Activity and the Delay Before and After Properties within the Activities are not working. I want the automation to delay between click activities within a browser. Any tips would be very helpful!

Hi,

Delay After/Before within activity is hardcoded delay it is not a best practice. instead of that we have to use conditional delay. if you use conditional delay you will not face any issues in Ui automation. you can place these conditional delay between click activities. please refer the below thread for more clear explanation. thanks.

@kirankumar.mahanthi1 Thank you for this! Very helpful and seems like it will be a solution to my problem. Only issue is my UiPath does not seem to have the “Check App State Activity”, do you know how I can get this?

Thanks!

Your welcome.

i think you are using classic design experience. in this case you can use Element exist activity for the conditional delay. please refer the below link it will help you to understand how to use this conditional delay and you have to keep the max time taken for the Ui element to load in your application.

Hi

Welcome to uipath forum

Usually Delay activity or delay before and after with UI based activities will work for sure if it is kept within any sequence of activities

when it comes to delay before or delay after property make sure it is more than the default value
**For delay before - 200 milliseconds is Default value

For delay after - 300 milliseconds is default value**

Only if the value is more than this with those properties it will take same delay
And for Delay activity it will take TimeSpan as input

But for this

the best practice would be using UI activities that validate an element presence like

1. Element exists
2. On element appear
3. On element vanish
4. Wait element vanish
5. Check app state

There is an advantage with check app state activity compared to others - it Can also monitor an entire application for changes, not only a single UI element

You can find all the first 4 activities in classic mode and last one - check app state in modern mode of experience

To toggle between these two experience

  • enable or disable the modern experience for a project, in the Project panel, select Project Settings , then use the Modern Design Experience toggle from the General tab and reload the project.
    :information-source: Note: You can enable the modern experience for projects created in Studio versions prior to v2020.10, which use the classic experience by default.

Hope this would help you resolve this

Cheers @alexa.coyle

I am using Check App State but I’m seeing an unintended delay.

  1. Use Application/Browser activity to open chrome for the user and navigate to a website. This website does not load until the user navigates several popups that were too difficult to automate.

  2. While the user is dealing with the popups, the automation brings up a message box that says: Please log into the website, then click OK.

  3. After the login msg box activity, use Check App State to verify that the user has successfully logged into the web app. The Check App State activity will display a “sucess” msg box if an element from the website appears, and a “fail” msg box if the element does not appear.

  4. To test the workflow, I click on the msg box OK button but without logging into the website.

The automation works properly, but when I click the OK message box without logging into the website, there is an unexpected delay of about 1.5 minutes, before the “fail” msg box shows up.

There are quite a few time related properties in Check App State, but after fiddling for an hour, I cannot see what is causing the delay. The automation should continue instantly after you click the OK button in the Please Login msg box.