Forum Discussion
Please post a screenshot or give an example to elaborate.
- abrar2210 years agoFrequent Contributor
There is Element which Exists in different Windows or Strategies but in one Window it shouldn't be there and I have chcek that it doesn't exist in that window.
We have a .Exist method to check if the element is there but is there any method or way to check that it is not there?
Thanks
- djadhav10 years agoRegular Contributor
If the .Exists method returns false that means it it not there.
- abrar2210 years agoFrequent Contributor
True. But my Tests script is failing because TestComplete is throwing error that it cant find the element. (see attached)
function vElementNotExists(NameMapAlias) {
{
if(NameMapAlias.Exists==False)
{
Reporter.vCheckpoint("Check Element Not Exists: PASS", "ClassName: " + NameMapAlias.ClrFullClassName + ": Object Not found ", 100 );
}
else
{
Reporter.vError("Check Element Not Exists: Fail", "ClassName: " + NameMapAlias.ClrFullClassName + ": Object found ", 100 );
}
}}