# Dynamic Wait

**URL:** <https://forum.uipath.com/t/dynamic-wait/129710>\
**Category:** Help\
**Tags:** uiautomation, activities\
**Created:** [July 1, 2019, 9:52am UTC](https://forum.uipath.com/t/dynamic-wait/129710 "2019-07-01T09:52:54Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![Siddharth\_Shankar](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/siddharth_shankar/32/76445_2.png) [@Siddharth\_Shankar](https://forum.uipath.com/u/Siddharth_Shankar)\
**Post date:** [July 1, 2019, 9:52am UTC](https://forum.uipath.com/t/dynamic-wait/129710/1 "2019-07-01T09:52:54Z")

</div>

Hi,  
I have a scenario , The robot open the Remote desktop and starts an applications. After staring one message appear which need to be clicked . But the time under which the message box appear is not fixed. How can i use a dynamic wait till the message box does not appear.  
Note : This all activity will be done on Remote desktop.  
Any help will really appreciated.

---

<div class="post-metadata">

**Author:** ![RobertD](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/robertd/32/176862_2.png) [@RobertD](https://forum.uipath.com/u/RobertD)\
**Post date:** [July 1, 2019, 9:55am UTC](https://forum.uipath.com/t/dynamic-wait/129710/2 "2019-07-01T09:55:28Z")

</div>

Please check:

> [@Dynamic Wait in UiPath](https://forum.uipath.com/t/dynamic-wait-in-uipath/70072/10):
>
> Yes even I would like to see an example that uses the Element exists activity with a while loop. Please post an example urgently.

It might give you a starting point.

---

<div class="post-metadata">

**Author:** ![ImPratham45](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/impratham45/32/161516_2.png) [@ImPratham45](https://forum.uipath.com/u/ImPratham45)\
**Post date:** [July 1, 2019, 9:55am UTC](https://forum.uipath.com/t/dynamic-wait/129710/3 "2019-07-01T09:55:42Z")

</div>

u can use click image activity with maximum timeout property  
means put 99999999 in timeout  
but u has to be sure it will come!

---

<div class="post-metadata">

**Author:** ![Siddharth\_Shankar](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/siddharth_shankar/32/76445_2.png) [@Siddharth\_Shankar](https://forum.uipath.com/u/Siddharth_Shankar)\
**Post date:** [July 1, 2019, 10:03am UTC](https://forum.uipath.com/t/dynamic-wait/129710/4 "2019-07-01T10:03:13Z")

</div>

I looked through the flow. There i can see that it is using Element Exist activity which has an boolean output. But since i am working on remote desktop will Element Exist will work ? Since the UIpath will treat everything as an image. And Find Image output is not boolean

---

<div class="post-metadata">

**Author:** ![Siddharth\_Shankar](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/siddharth_shankar/32/76445_2.png) [@Siddharth\_Shankar](https://forum.uipath.com/u/Siddharth_Shankar)\
**Post date:** [July 1, 2019, 10:04am UTC](https://forum.uipath.com/t/dynamic-wait/129710/5 "2019-07-01T10:04:42Z")

</div>

So in this case it will click as soon as the images appears ?

---

<div class="post-metadata">

**Author:** ![ImPratham45](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/impratham45/32/161516_2.png) [@ImPratham45](https://forum.uipath.com/u/ImPratham45)\
**Post date:** [July 1, 2019, 10:05am UTC](https://forum.uipath.com/t/dynamic-wait/129710/6 "2019-07-01T10:05:22Z")

</div>

yes it will click once it gets an image

---

<div class="post-metadata">

**Author:** ![ImPratham45](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/impratham45/32/161516_2.png) [@ImPratham45](https://forum.uipath.com/u/ImPratham45)\
**Post date:** [July 1, 2019, 10:06am UTC](https://forum.uipath.com/t/dynamic-wait/129710/7 "2019-07-01T10:06:42Z")

</div>

Dont use find image insted use image exist it will give u an boolean op  
if doesnt exist then again iterate in loop to image exist

---

<div class="post-metadata">

**Author:** ![Siddharth\_Shankar](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/siddharth_shankar/32/76445_2.png) [@Siddharth\_Shankar](https://forum.uipath.com/u/Siddharth_Shankar)\
**Post date:** [July 1, 2019, 10:09am UTC](https://forum.uipath.com/t/dynamic-wait/129710/8 "2019-07-01T10:09:23Z")

</div>

thanks a lot

---

<div class="post-metadata">

**Author:** ![ImPratham45](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/impratham45/32/161516_2.png) [@ImPratham45](https://forum.uipath.com/u/ImPratham45)\
**Post date:** [July 1, 2019, 10:09am UTC](https://forum.uipath.com/t/dynamic-wait/129710/9 "2019-07-01T10:09:50Z")

</div>

You got a soluntion???

---

<div class="post-metadata">

**Author:** ![Siddharth\_Shankar](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/siddharth_shankar/32/76445_2.png) [@Siddharth\_Shankar](https://forum.uipath.com/u/Siddharth_Shankar)\
**Post date:** [July 1, 2019, 10:12am UTC](https://forum.uipath.com/t/dynamic-wait/129710/10 "2019-07-01T10:12:11Z")

</div>

will try with Image exist and then checking it with if condition and putting a delay

---

<div class="post-metadata">

**Author:** ![ImPratham45](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/impratham45/32/161516_2.png) [@ImPratham45](https://forum.uipath.com/u/ImPratham45)\
**Post date:** [July 1, 2019, 10:13am UTC](https://forum.uipath.com/t/dynamic-wait/129710/11 "2019-07-01T10:13:53Z")

</div>

use flowchart instead of if  
so that u can loop it  
 ![image](https://global.discourse-cdn.com/uipath/original/3X/4/c/4cbda7cd345746952e16641d8bf7c6359a43a237.png)
