- lokesh_chandra
- Posts : 6
Join date : 2011-05-24
Selenium IDE unable to identifydynamic ID of web element
Tue May 24, 2011 5:00 pm
Hi everyone,
I am new to this forum but found it quite helpful.I have an issue regarding Selenium IDE. I am testing a web page which has some web elements with dynamic changing properties. I was trying to click on that particular element but it says element not found. I have tried everything xpath, css , html firebug,regular expression everything but still it is giving error. I want to know when we run the script every time the web page refreshes and generates a new id for that particular element. Is there anyway that Selenium IDE can identify the target with dynamic changing properties. Even I tried record and play but once you record and playback the same script it gives an error.Please help me solve this issue. Thanks in advance.
Xpath:/html/body/table[2]/tbody/tr[1]/td[2]/center/div/table/tbody/tr[@id='null_slv_r']/td[@id='null_slv_c']/table/tbody/tr/td/form/table/tbody/tr[6]/td[2]/span[@id='span_picker7224']/a[@id='a_picker7224']/img
(Evey time the above id is changing whenever the page gets refreshed.)
I am new to this forum but found it quite helpful.I have an issue regarding Selenium IDE. I am testing a web page which has some web elements with dynamic changing properties. I was trying to click on that particular element but it says element not found. I have tried everything xpath, css , html firebug,regular expression everything but still it is giving error. I want to know when we run the script every time the web page refreshes and generates a new id for that particular element. Is there anyway that Selenium IDE can identify the target with dynamic changing properties. Even I tried record and play but once you record and playback the same script it gives an error.Please help me solve this issue. Thanks in advance.
Xpath:/html/body/table[2]/tbody/tr[1]/td[2]/center/div/table/tbody/tr[@id='null_slv_r']/td[@id='null_slv_c']/table/tbody/tr/td/form/table/tbody/tr[6]/td[2]/span[@id='span_picker7224']/a[@id='a_picker7224']/img
(Evey time the above id is changing whenever the page gets refreshed.)
- freeskyAmateur
- Posts : 72
Join date : 2011-04-13
Re: Selenium IDE unable to identifydynamic ID of web element
Fri May 27, 2011 9:01 am
in xpath,you can use 'contains()' to locate the dynamic element.
for instance,//span[container(@id,'span')]
for instance,//span[container(@id,'span')]
- lokesh_chandra
- Posts : 6
Join date : 2011-05-24
Thanks for your feedback!
Fri May 27, 2011 5:59 pm
Hi freesky,
I must thank you for your feedback.Finally
it's working now and good to see so much support on this forum. Keep up
the good word. There is one request kindly reply for the questions
little bit early. Rest everything is really helpful on here.
Thanks
I must thank you for your feedback.Finally
it's working now and good to see so much support on this forum. Keep up
the good word. There is one request kindly reply for the questions
little bit early. Rest everything is really helpful on here.
Thanks
- PriyankaRegular Participant
- Posts : 27
Join date : 2010-10-04
Re: Selenium IDE unable to identifydynamic ID of web element
Tue May 31, 2011 4:09 pm
freesky
tnx for sharing
tnx for sharing
Permissions in this forum:
You cannot reply to topics in this forum
|
|