The method sendKeys(CharSequence[]) in the type WebElement is not applicable for the arguments (String) | Selenium Forum
L
lakshmi Posted on 09/10/2019

L
lakshmi Replied on 10/10/2019

On sendkeys, I am not able to pass the string as parameter

This is on module 12 and trying using the id type to find the elements and send the keys.

Please help.

driver.findElement(By.id("userid")).sendKeys("uytuy");

I am seeing below error:

The method sendKeys(CharSequence[]) in the type WebElement is not applicable for the arguments (String)

 

 


A
Ashish Thakur Replied on 10/10/2019

Which version of JDK are you using?

Make sure that you are using JDK 8 only.


L
lakshmi Replied on 10/10/2019

Thanks. It worked when I updated the compiler compliance level.