I am trying to click an image during automated testing using Watij. I am specifically trying to use SymbolFactory's src (instead of name, id, etc.) as detection.
HTML:
<input type="image" src="lib/img/btnFindStore.png" style="border-width:0px;">
Java:
ie.image(SymbolFactory.src, "lib/img/btnFindStore.png").click();
I am wondering why it throws watij.runtime.UnknownObjectException at this line.
Thanks!
Yeah, so using ie.button here is the solution
ie.button(SymbolFactory.src, "lib/img/btnFindStore.png").click();