Search
 
 

Display results as :
 


Rechercher Advanced Search

Latest topics
» how to connect DB in selenium webriver
Fri Oct 06, 2017 4:09 pm by anbarasi

» How find any text in browser screen and click on it?
Thu Oct 05, 2017 2:02 pm by sandeepkommineni

» Selenium Webdriver
Tue Oct 03, 2017 1:35 pm by PiyushBiswas

» GRID setup tutorial.
Wed Sep 27, 2017 4:29 pm by johnyapp

» Drag & Drop Between Windows Using Selenium Driver
Wed Sep 27, 2017 2:10 pm by 26rondel

» Check if window is closed / verify input
Sat Sep 23, 2017 10:21 pm by brainstir

» How to work on pages with AJAX in selenium?
Mon Sep 18, 2017 6:08 pm by azharuddin

» pause test until user press a key like F2
Wed Aug 09, 2017 11:10 pm by djnforce

» Selecting the input for auto populating element
Sat Jul 29, 2017 7:53 pm by kdabbara

Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

selenium.type("id","value"); does not work

View previous topic View next topic Go down

selenium.type("id","value"); does not work

Post by sunil_sn on Sat Mar 10, 2012 2:51 am

Here is my sample code:

selenium.open("/test.php");

selenium.waitForPageToLoad("30000");

selenium.type("name","TestName");

selenium.type("description","TestDescription");

selenium.click("OK");

selenium.waitForPageToLoad("30000");

When I execute this script, I get the name field populated with but description field is skipped and OK button is clicked. Since both name and description both are text field and are mandatory field on clicking OK button the task is not completed as the description textbox is empty.

to debug I entered another line of code before selenium.type("description","TestDescription"); as

System.out.println(selenium.isElementPresent("description"));

and on execution I got the value as true.

Selenium server is giving Result as OK for all the lines above but still the field is not getting populated by data

So, I added one more line

System.out.println(selenium.isEditable("description));

for which I get the following error:

Exception in thread "main" com.thoughtworks.selenium.SeleniumException: ERROR: E
lement description is not an input.
at com.thoughtworks.selenium.HttpCommandProcessor.throwAssertionFailureE
xceptionOrError(HttpCommandProcessor.java:100)
at com.thoughtworks.selenium.HttpCommandProcessor.doCommand(HttpCommandP
rocessor.java:94)
at com.thoughtworks.selenium.HttpCommandProcessor.getString(HttpCommandP
rocessor.java:265)
at com.thoughtworks.selenium.HttpCommandProcessor.getBoolean(HttpCommand
Processor.java:338)
at com.thoughtworks.selenium.DefaultSelenium.isEditable(DefaultSelenium.
java:519)



I verified the .php file and that code never mentions of uneditable or so...

Can anyone help me how to work around this??

sunil_sn

Posts : 3
Join date : 2012-03-10

Back to top Go down

Re: selenium.type("id","value"); does not work

Post by Bhuvaneswari on Wed Mar 21, 2012 7:11 pm

I am too facing now a similar problem. selenium.type("id=ID", "VALUE"); this line of code not working for me in few places for my web page. wherein this problem is not found with Selenium IDE, there it runs properly.

Bhuvaneswari
Regular Participant
Regular Participant

Posts : 30
Join date : 2011-09-30
Location : India

Back to top Go down

Re: selenium.type("id","value"); does not work

Post by sunil_sn on Wed Mar 21, 2012 8:13 pm

I too am not seeing this with IDE, only with RC. I mean it works perfectly fine in selenium IDE but not in RC

sunil_sn

Posts : 3
Join date : 2012-03-10

Back to top Go down

Re: selenium.type("id","value"); does not work

Post by Sponsored content


Sponsored content


Back to top Go down

View previous topic View next topic Back to top

- Similar topics

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