Quantcast
Channel: Silk Performer
Viewing all articles
Browse latest Browse all 4084

Forum Post: RE: How to test either this element or that element case?

$
0
0
Since you say one of the two elements must exist then the solution is easy. Find just one of the two elements, if it exists then click it, if it doesnt exist then the other must so click the other. Pseudocode: if (BrowserFind(HANDLE_DESKTOP, "//div[@class='classA']", false, 3000, true) = HANDLE_INVALID) then BrowserClick("//div[@class='classB']|, BUTTON_Left, "classB"); // A doesn't exist so B must exist so click B else BrowserClick("//div[@class='classA']|, BUTTON_Left, "classB"); // A does exist so click it. end;

Viewing all articles
Browse latest Browse all 4084


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>