Could we please have an activity of “Element NOT exist”? It’s quite useful to use with “Retry scope” activity.
Thanks!
S.
@lakshman & @ashley11: There’s no Reply bttn for me, so I am editing here.
I would like to use “Element NOT exist” activity in the “Condition” section of a “Retry scope” activity = Retry some activity until the element in “Element NOT exist” activity not existing.
@ashley11: My idea is that: For example: I would like robot to keep clicking to a button (eg 3 times) until a popup is not existing. Without using Retry scope: if I use “Wait Image/Element vanish” or “Element exist” activity, I need to put these activities in a Flowchart, then use “Flow decision”/“If” activity, create a variable to know if the popup is still existing or not.
So, instead of using many steps above, if we have an “Element NOT existing” activity, I can simply put the activity to the “Condition” section and put the “Click” activity to the “Action” section of a “Retry scope” .
set TIMEOUT as per your requirement
Here if you set time for 5 minutes and the element vanishes before 3 minutes it will move ahead immediately after the image or element vanishes here you are setting the time not to compulsorily wait till 5 mins at the max it will wait for 5 mins after that that it will throw error. If image or element vanishes before the set time it will move on to other activity.
see the concept here is take an example: not Sting.IsNullOrEmpty(Any_String) will check the string is not empty String.IsNullOrEmpty(Any_String) will check the string is empty
here im using same method String.IsNullOrEmpty(Any_String) for getting 2 different output.
hope you got the point.
hope that helps
@ashley11 is on to something in regards of using the Wait Image Vanish activity. Though why should you use image based search, when you can use the Wait Element Vanish.
I agree that there could be use case for what you are asking for.
Until then, you can use the Wait Image Vanish as the last action. If it fails, which it will when it finds the element, it will try again.
I want the exact same thing.
I need it when i need to use some elements in popup when automating browsers.
Either that or change in Retry Scope so we can use negatives in Condition (a checkbox perhaps)
Hi, I too want this. There are occasions, such as when checking that an applicaiton is not already open before opening it, that I want to look for a window and if NOT there continue else throw an exception.
I currently achieve this by enclosing FindElement in a TryCath, with a Throw SE immediately after the FundElement in Try. Then if not found, the Throw SE not executed.
It works fine but has to wait for timeout and in debug you have to hit Continue each time.
The existing activities allow you to check if something doesn’t exist. I don’t understand why we need a separate activity for something we can already do with existing activities.
What I want is the opposite.
It is that if it finds an exception inside that Do…While scope to retry everything again. (it was an workaround @minolp mentioned above)
What existing activity allows me to check if something doesn’t exist as fast and straight forward as a “NOT” activity on an “Element Exists” would do ?