I tested your script to click confirm popup with the “Click” command and it does not work all the time.
Here is how to reduced the error on chrome
- Run your script below → it loads the page and click the [OK] button from the popup
- Comment the “open” URL command out so that it is not called again
- Refresh the page pressing the F5 button
- Run the script again (this time without a fresh call of the page) → it presses [Cancel Button]
{
"Name": "popup1",
"CreationDate": "2025-2-2",
"Commands": [
{
"Command": "open",
"Target": "https://testpages.herokuapp.com/styled/alerts/alert-test.html",
"Value": "",
"Description": ""
},
{
"Command": "click",
"Target": "id=confirmexample",
"Value": "",
"Description": "Opens dialog, but uivision catches it and closes it"
},
{
"Command": "storeText",
"Target": "id=confirmexplanation",
"Value": "a",
"Description": "Extract result text from website"
},
{
"Command": "echo",
"Target": "text=${a}",
"Value": "green",
"Description": ""
}
]
}