Click link= @POS=3 stopped working

I have been using this to click a link on a page without problem until recently and I can’t figure out why. It just says “timeout reached when looking for element”

Is it possible to target a particular area of a website, then get it to click the third link?

Maybe the page has changed?

Is it possible to target a particular area of a website, then get it to click the third link?

This is what @pos is for :wink:

You can also use XPath:

XPath query to get nth instance of an element:

Example xml to search:

<div>
  <form>
    <input id="abc" />
   </form>
</div>

<div>
  <form>
    <input id="abc" />
  </form>
</div>

<div>
  <form>
    <input id="abc" />
  </form>
</div>

Solution: (Note the [2] at the end)

xpath=(//input[@id="abc"])[2]

Sorry! I should have been more specific, I mean, first specify a div (for example) and then get it to go through links? I don’t understand why it’s not clicking the third link, at the moment, even if it’s changed…

Annoyingly the xpath of the element changes depending on what stylesheet is applied… it also doesn’t have an id… it does have a class name though, can that be used somehow? (there will be multiple buttons on the page with the same classname, though)

For clarity, it is this “Book Now” button that I am trying to target:

<td class="carResultRow_OfferInfo-toolbar" rowspan="2">
<a href="javascript:document......" class="carResultRow_OfferInfo-btn-primary" onclick="trackBookNow();">
<span class="a11y">or Similar </span>
<span>Book Now</span>
<div class="book-loader"></div>
</a>

actually
link= @POS=
stopped working since 5.1.5
it works when i use 5.0.8 with the same macro:

{
  "Name": "000_test_001",
  "CreationDate": "2019-8-6",
  "Commands": [
    {
      "Command": "open",
      "Target": "https://ui.vision/docs",
      "Value": ""
    },
    {
      "Command": "clickAndWait",
      "Target": "link=csvRead@POS=2",
      "Value": ""
    }
  ]
}

This has happened for me too. In the new version, all of my macros with any reference to “Link=” have stopped working.

@peterpeter @ggreene09 This is a regression error and not related to @sooshi’s issue . It is fixed with V5.1.8 which will be available in a few hours. For a workaround see Kantu no longer able to click on links in popups after 5.1.5 update

1 Like

@sooshi difficult to say what is wrong without a direct link to the page

@admin thanks for everything you guys do… for real. you make my life 100x easier