I’ve had this problem a couple of times, but this time, I am unable to find a workaround, so I hope someone out there can help me find a solution.
I am running a process on a website, and sometimes I need to dismiss/accept a cookie notification.
I use the “Element exist” activity to check, whether the I need to click on the cookie banner before continuing The problem is, that UIPath validates my selector regardless to whether the banner exists or not.
I use the following selector:
<html app='chrome.exe' title='Erhverv'/>
<webctrl id='coiBannerHeadline' tag='H2' aaname='Vi bruger cookies ' />
There are a number of unselected items as well - I have tried using almost every combination of items.
I have noted, that there are people that have had the same issue, but I have haven’t found a solution that worked for me so far.
i think you have to use element exist with the get attribute activity and look for the attribute called visibility. please refer the below thread for more guidance. thanks.
Hi there @lapet,
I hope you are having a great day!
Most likely, the element still exists, but upon dismissal, it has it’s visibility set to false.
There are a few ways to handle this, you could:
Use a Get Attribute - Set to Visibility.
Use a Find Element - With Visibility set to True.
The above will allow you to check, not only that it exists, but whether it is visible on the screen.
Please let me know if you have any questions.
Thanks once again for your support,
Josh
I ended up using the Get Attribute-activity using the “relativeVisibility”-attribute.
I tried some of the other proposed solutions, but this was the best match for me.
Thanks to everyone for your suggestions and especially for the solution