Take the 2-minute tour ×
Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. It's 100% free, no registration required.

I am new to Selenium WebDriver World. I am trying to work on a script to Add a Person in PeopleSoft HCM Application. Basically, On the Personal Data Main page, you first start by adding a Effective Date in to a Date Field and click on Add Name button that opens a Sub Page on the Main page. The Sub Page has First Name , Middle Name , Last Name etc fields. You enter this fields and click OK to go back to Main Page and carry on other data entries.

When I recorded through Selenium IDE, it clicks on the Add Name Button and the sub page opens and the IDE can enter text to the name fields. However when I am using the Web Driver Code, it is not able to push the data to the sub page.

How can I get hold of the sub page through the code. I tried the driver.switchTo().window command , and it is not working.

Any Help on this would be a great.

Thanks

enter image description here

Raj

share|improve this question
1  
It doesn't look like a new window opens, which is why, I think, the switchTo command doesn't work. Does the page use iFrames? Can you paste the HTML code here? –  Yash Jun 6 '14 at 6:31
    
This looks like an inline DIV that's being made visible/invisible depending on circumstances, probably with an AJAX call somewhere behind it. –  Kate Paulk Jun 6 '14 at 10:59
    
I'm sailing in the same boat as you. Currently automating testing for PeopleSoft using Selenium and I'm blocked for this sub-page. Were you able to find any solution for this? –  Anjana Aug 3 at 21:41

1 Answer 1

It looks like only a new modal dialog is open, not a window. So you should query the modal dialog and then its inside elements to get control.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.