Forum Discussion
Hi,
Myself personally I like to use if else statements to look if a object is visible on screen or not, and then continue.
If object is invisible refresh the browser code:
function IfObjectInvisible()
{
if(!Project.Variables.PageObject.VisibleOnScreen){
Aliases.browser.Refresh()
}
else{
return true;
}
}
If Object is visible, continue, else refresh the browser
function IfObjectVisible()
{
if(Project.Variables.PageObject.VisibleOnScreen){
return true;
}
else{
Aliases.browser.Refresh()
}
}
I dont know if its a great idea to add an event for ignoring errors. If you were going to, I would recommend adding that within the logic itself, not an event for every error.
- Capricornus4 years agoContributor
Hi Sonya,
that's a workaround that I can use but the problem itself is not solved this way: If an error handler for warnings is defined, try --- catch does not work as it should.
mattb wrote:Hi,
Myself personally I like to use if else statements to look if a object is visible on screen or not, and then continue.
If object is invisible refresh the browser code:function IfObjectInvisible()
{
if(!Project.Variables.PageObject.VisibleOnScreen){
Aliases.browser.Refresh() rapidfs account
}
else{
return true;
}
}
If Object is visible, continue, else refresh the browserfunction IfObjectVisible()
{
if(Project.Variables.PageObject.VisibleOnScreen){
return true;
}
else{
Aliases.browser.Refresh()
}
}
I dont know if its a great idea to add an event for ignoring errors. If you were going to, I would recommend adding that within the logic itself, not an event for every error.Thanks for the update. I'll be sure to keep an eye on this thread.