Is eValid able to tell if an page element is there or not

Applying eValid to AJAX applications that require advanced DOM-based methods.

Is eValid able to tell if an page element is there or not

Postby DaveTroy » Thu Aug 29, 2019 8:12 am

Morning.

I was wonder if eValid has the ability to know if an element is NOT present in a page?

Thanks
DaveTroy
 
Posts: 1
Joined: Thu Aug 29, 2019 8:05 am

Re: Is eValid able to tell if an page element is there or no

Postby eValid » Fri Aug 30, 2019 9:26 am

DaveTroy wrote:Morning.

I was wonder if eValid has the ability to know if an element is NOT present in a page?

Thanks


Thanks for posting your element question DaveTroy.

We are assuming you have run a search using the IndexFindElement or IndexFindElementEX commands, as described below:

http://e-valid.com/Products/Documentati ... indElement

http://e-valid.com/Products/Documentati ... nt.ex.html


These commands always start at the current value of "sourceIndex" which present to zero at the start of any playback, and is left at the value of the most recent prior search (with either command) in the same playback.

So, typically (but not necessarily) you first increment the source index by this command:

IndexMove 1

then you do the search for the next object.

If the search commands does not find it then it does NOT change the value of sourceIndex.

If the sourceIndex changes you found something new; if it is unchanged, then that particular element is not in the page at the time you did the search.

The only caveat is that the command requires a constant page...if during the search the page changes -- it can, if it is an AJAX application -- then you may falsely find that the element is there (or not there) when it actually isn't there (or actually is there).

That's the nature of AJAX.

Hope that helps you looks for signs if the element is present or not.


-- eValid Support
eValid
 
Posts: 1952
Joined: Tue Jan 01, 2008 12:48 pm
Location: USA


Return to AJAX Applications & DOM Processing

Design Downloaded from free phpBB templates | free website templates | Free Web Buttons