How to click element with RanoreXpath

Best practices, code snippets for common functionality, examples, and guidelines.
johnzer
Posts: 16
Joined: Thu Aug 18, 2016 9:27 pm

How to click element with RanoreXpath

Post by johnzer » Tue Aug 23, 2016 4:39 pm

Hello,

I am working on testing an application. We want to make the tests independent of the position of the element on the screen. How would I go about clicking on an element using it's RanoreXPath, which I already determined using Ranorex Spy?

Thanks.

krstcs
Ranorex Guru
Posts: 2683
Joined: Tue Feb 07, 2012 4:14 pm
Location: Austin, Texas, USA

Re: How to click element with RanoreXpath

Post by krstcs » Tue Aug 23, 2016 7:15 pm

I would suggest reading the user guide completely. It explains this question, as well as many others, in great detail. Ranorex was designed from the ground up to not rely on element position to identify elements. It can do it that way as well, if needed, but it was designed to not need it.

http://www.ranorex.com/support/user-guide-20.html

Also, there are several blog posts and videos that demonstrate basic Ranorex functionality and design patterns, please read/watch them. Work through the tutorials and look at the example projects provided with Ranorex Studio's installation.

After you have done that, if you still have questions about how to implement these ideas, come back to the forums and ask specific questions about the area you are having trouble with.

We can and will help as much as we are able, but if you haven't taken the time to read and view the available information that Ranorex provides, then it will be hard for anything we tell you to make sense or be immediately useful.

In addition, when raising issues on the forums, please always include as much and as detailed information as possible, including:

Ranorex version
Windows version
Full text of any error messages
Ranorex Snapshots (NOT screenshots) and RanoreXPath of elements in question
Technology of system-under-test (SUT)

This will help us all be on the same "page" when trying to diagnose the issues.
Shortcuts usually aren't...