Forum Discussion

mfremont-smith's avatar
mfremont-smith
Occasional Contributor
2 years ago

Click occurs outside of element coordinates

What would cause a click event to occur outside of the object coordinates for an element discovered using FindElement(xpath).Click()?

 

Is this a known issue?

1 Reply

  • Lots of things could affect it, for instance, a change in the monitor being used or the resolution on the monitor, a resizing of the browser, or a change in the program. Anything that changes the view of the UI could cause this.

     

    Rather than using coordinates to locate an object, use properties of the object to find it. That's a more reliable and stable way of doing it.

     

    Here's some information to get you started:

    https://support.smartbear.com/testcomplete/docs/app-objects/common-tasks/searching.html