Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Problems with URL as Object identifier???
#1
Solved: 11 Years, 4 Months, 3 Weeks ago
I have two objects that are similar in every way except for the URL. In that case, the object I want to ID is something like:

.../Activity/111111/2/Detail.aspx

The one I do not want is:

.../Activity/111111/1/Detail.aspx

I could use the Index, but these objects are in a list that could potentially change either adding or removing objects in front of them. So, the index number would be incorrect. Same can be said for using the Visual relation identifier - All the items like the select button or links to other things are identical and would need to be based on the Index value.

I tried using the URL and/or Href. Neither were able with the default. If I add the URL and remove the Index, it cannot find the item any longer. Now, the full url includes the www.website001-test-environment.com/. So, I thought I would try a regular expression:

[0-9, a-z, \., \-, \:, \/]*/Activity/1123855/2/Details\.aspx

Now, QTP says there are more than one object with the same values. I verified there are no other locations on the site for this link.

Did I screw up the regular expression or is there a better property to use?

Any suggestions would be appreciated! I am spending too much time one this as it is.
Reply
#2
Solved: 11 Years, 4 Months, 3 Weeks ago
I dont know if it really matters answering now, but you could have simply used the regular expression ^.*/Activity and it would have worked. One thing is like you got to click Ok on the dialog, which asks you if you want to treat the symbols like . as they are but not as regular expressions.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Problems with Text color recognition Treirk 0 1,148 06-17-2019, 12:19 PM
Last Post: Treirk
  Description about Types of Ordinal Identifier abhijit.airforce 1 2,536 12-27-2013, 02:57 PM
Last Post: Ankesh
  QTP recording problems Masa 2 2,466 11-11-2012, 08:28 AM
Last Post: Masa
  problems with remote machines locking or going to sleep usha gowda 3 3,681 10-15-2012, 11:36 PM
Last Post: agarwl.anurag
  url value sia sharma 0 2,242 07-02-2012, 12:30 PM
Last Post: sia sharma

Forum Jump:


Users browsing this thread: 1 Guest(s)