I am using Selenium Web Driver
for Fire Fox to automate a web page inPython
.
The issue is that sometime for some elements i am getting NoSuchElementException
even though the element is present with the id i am searching for.
I am using find_element_by_id(id)
method.
My code is
d = webdriver.Firefox()
elm5 = d.find_element_by_id("ctl00_bodyContent_tabGroupAdmin")
elm5.click()
The HTML for that element is:
<div id="ctl00_bodyContent_tabGroupAdmin" class="tab">
<div onclick="OpenTab(3); DisableProgressBarDisplay(); return false;">
Group Administrators</div>
<div class="cap_right">
</div>
</div>
Has anyone faced the same issue? Please suggest some work around.
Thanks