Click empty span elements
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-08-2014
09:59 PM
06-08-2014
09:59 PM
Click empty span elements
We have a HTML object with the below structure...
<span class="glypicon-fast-back"></span>
<span class="glypicon-back"></span>
<input type="numeric" />
<span class="glypicon-forward"></span>
<span class="glypicon-fast-forward"></span>
I am selecting the span elements using the QuerySelector("span.glyphicon-back") method and then trying to click the selected element, but the test run fails stating that the element does not support the click method. I have overcome this in the past by changing the selector to include an element within the span, but in this instance there is nothing else to select.
Has anyone else seen this issue?
<span class="glypicon-fast-back"></span>
<span class="glypicon-back"></span>
<input type="numeric" />
<span class="glypicon-forward"></span>
<span class="glypicon-fast-forward"></span>
I am selecting the span elements using the QuerySelector("span.glyphicon-back") method and then trying to click the selected element, but the test run fails stating that the element does not support the click method. I have overcome this in the past by changing the selector to include an element within the span, but in this instance there is nothing else to select.
Has anyone else seen this issue?
10 REPLIES 10
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-11-2014
01:57 AM
06-11-2014
01:57 AM
Thanks hanya, but I'd rather not have to get the HTML changed to enable to Test Complete testing.
I think for now I'll just do a click(x,y) call as all the spans I need to click have absolute positioning so won't be moving around.
I think for now I'll just do a click(x,y) call as all the spans I need to click have absolute positioning so won't be moving around.

- « Previous
-
- 1
- 2
- Next »
- « Previous
-
- 1
- 2
- Next »