Selenium Forum: Functional And Regression Testing Tool.
Would you like to react to this message? Create an account in a few clicks or log in to continue.
Search
Display results as :
Advanced Search
Latest topics
AEM Training | Free Online DemoWed Apr 21, 2021 5:45 pmazharuddin
c# PageFactory - issue initializing elementsFri Nov 01, 2019 8:40 pmthegoatboy
Selenium making automatic connection to random urlsMon Jul 08, 2019 12:58 pmrepairtechsolutions1
How can we design the custom framework in Selenium RCMon Jun 24, 2019 2:26 pmrandybonnettes
What are the new features in Selenium 3.0Tue Jun 18, 2019 5:37 pmpappyvicky
What are you using Selenium for? Fri Apr 12, 2019 3:52 amzhl
LIMITATIONS OF SELENIUMWed Apr 10, 2019 11:23 amswara
Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

Go down
avatar
QASelenium
Posts : 2
Join date : 2011-11-30

Selecting item from a drop down richfaces control type Empty Selecting item from a drop down richfaces control type

Thu Dec 01, 2011 1:01 am
I am new to Selenium. Have been exploring for the last 2 weeks and now stuck with this issue for the past 7 days. I have a drop down list in my UI under test. IDE is not recording the selection. What it records is below
driver.findElement(By.xpath("//div[@id='totalForm:bodyTile:JobDetailsTabView:JobLocationDropDownlist']/span[3]")).click(); OR in other words
Command : click
target : //div[@id='totalForm:bodyTile:JobDetailsTabView:JobLocationDropDownlist']/span[3]

I did my findings and tried combination of command like type,typekeys and fireevent.

Stumbled on this forum, registered today and now posting, with hope of getting this resolved and make this forum my bible. Just like qaforums.

Thanks!
avatar
faramka
Professional
Professional
Posts : 143
Join date : 2011-09-15
Location : Poland

Selecting item from a drop down richfaces control type Empty Re: Selecting item from a drop down richfaces control type

Mon Dec 05, 2011 4:57 pm
Could you please paste some code which is responsible for showing drop down list?
You can use Firebug plugin in Firefox to copy the code.
avatar
QASelenium
Posts : 2
Join date : 2011-11-30

Selecting item from a drop down richfaces control type Empty Re: Selecting item from a drop down richfaces control type

Mon Dec 05, 2011 11:31 pm
faramka wrote:Could you please paste some code which is responsible for showing drop down list?
You can use Firebug plugin in Firefox to copy the code.
Exactly that is what I used to get insight of the objects info. BTW finally I was able to get thru this and below is the line of code after I exported IDE script to webdriver.
selenium.type("id=totalForm:bodyTile:JobDetailsTabView:WorkingTitleDropDowncomboboxField", "AQA");
selenium.click("id=totalForm:bodyTile:JobDetailsTabView:WorkingTitleDropDowncomboboxButton");
selenium.typeKeys("id=totalForm:bodyTile:JobDetailsTabView:WorkingTitleDropDowncomboboxField", "A");
selenium.fireEvent("id=totalForm:bodyTile:JobDetailsTabView:WorkingTitleDropDowncomboboxField", "keypress");
selenium.type("id=totalForm:bodyTile:JobDetailsTabView:customField_123512DropDowncomboboxField", "IT Serv Delivery HR & Finance");
selenium.click("id=totalForm:bodyTile:JobDetailsTabView:customField_123512DropDowncomboboxButton");
selenium.typeKeys("id=totalForm:bodyTile:JobDetailsTabView:customField_123512DropDowncomboboxField", "I");
selenium.fireEvent("id=totalForm:bodyTile:JobDetailsTabView:customField_123512DropDowncomboboxField", "keyup");
selenium.type("id=totalForm:bodyTile:JobDetailsTabView:JobLocationDropDowncomboboxField", "Wayne");
selenium.click("id=totalForm:bodyTile:JobDetailsTabView:JobLocationDropDowncomboboxButton");
selenium.typeKeys("id=totalForm:bodyTile:JobDetailsTabView:JobLocationDropDowncomboboxField", "W");
selenium.fireEvent("id=totalForm:bodyTile:JobDetailsTabView:JobLocationDropDowncomboboxField", "keyup");

But now I am having issue, where the click is not working for a link that worked in IDE. In IDE it works and is recorded as clickandwait() and in webdriver it is below line of code, when it fails for click. Any suggestions.
selenium.waitForPageToLoad("30000");
selenium.click("id=menubarTile:menuBarForm:NewJob_linkAnchor");
avatar
lalkota
Active particpant
Active particpant
Posts : 21
Join date : 2011-06-02

Selecting item from a drop down richfaces control type Empty Re: Selecting item from a drop down richfaces control type

Tue Dec 06, 2011 5:28 pm
Message reputation : 0% (1 vote)
Hello,

Visit this link

http://online-selenium-trainings.webs.com
http://seleniumtraining.in
http://seleniumtraining.blogspot.com/
Sponsored content

Selecting item from a drop down richfaces control type Empty Re: Selecting item from a drop down richfaces control type

Back to top
Permissions in this forum:
You cannot reply to topics in this forum