Hi,
I have a Xpath like
"/form[@title='Incoming Shipment']/element/element[@controlid='39851744']/element[@controlid='10']/combobox[@accessiblerole='ComboBox']"
In this Xpath, "[@controlid='39851744']" , the value part (39851744) changes every time the form is launched.Because of this I am getting "Element no found exception" within 30 seconds.
Please let me know how to handle the element id problem.
Regards,
Sam
Object Identification based on control id
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Object Identification based on control id
Hi,
have a look at following blog post, which will show you how to eliminate such dinamically generated attributes from your RanoreXPath:
http://www.ranorex.com/blog/eliminate-d ... norexpaths
Regards,
Tobias
Support Team
have a look at following blog post, which will show you how to eliminate such dinamically generated attributes from your RanoreXPath:
http://www.ranorex.com/blog/eliminate-d ... norexpaths
Regards,
Tobias
Support Team
Re: Object Identification based on control id
Or eliminate it manually to :
"/form[@title='Incoming Shipment']/element/element/element[@controlid='10']/combobox[@accessiblerole='ComboBox']"
"/form[@title='Incoming Shipment']/element/element/element[@controlid='10']/combobox[@accessiblerole='ComboBox']"
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Object Identification based on control id
Hi atom,
of course you can eliminate it manually, but I think it is really annoying if you have to adapt your RxPath after each Recording. Therefore I would also suggest you the way with the "Weights", because even then the recorder ignores this attributes.
Regards,
Peter
Ranorex Team
of course you can eliminate it manually, but I think it is really annoying if you have to adapt your RxPath after each Recording. Therefore I would also suggest you the way with the "Weights", because even then the recorder ignores this attributes.
Regards,
Peter
Ranorex Team
Re: Object Identification based on control id
Support Team wrote:Hi atom,
of course you can eliminate it manually, but I think it is really annoying if you have to adapt your RxPath after each Recording. Therefore I would also suggest you the way with the "Weights", because even then the recorder ignores this attributes.
Regards,
Peter
Ranorex Team
Hi ,
I have used regural expression and achived the required functionality
I have used "[@controlid~'[\d{8}]']" instead of "[@controlid='39851744']"
Thanks for your support