Back to Browse

How to solve "Webdriver cannot be resolved to a type" Error in Selenium?

122.4K views
Mar 11, 2022
10:32

In this video it shows how one can resolve the "Webdriver cannot be resolved to a type" error while working with selenium in Eclipse. The JAR files mentioned in the video can be downloaded from the below path: https://www.selenium.dev/downloads/ I hope you like this video. For any questions, suggestions or appreciation please contact us at: https://programmerworld.co/contact/ or email at: [email protected] Complete source code and other details of this video are posted in the below link: https://programmerworld.co/blogs/how-to-solve-webdriver-cannot-be-resolved-to-a-type-error-in-selenium/ The code is also copied below: import org.openqa.selenium.By; import org.openqa.selenium.WebDriver; import org.openqa.selenium.chrome.ChromeDriver; public class ErrorDemo { public static void main(String[] args) { // TODO Auto-generated method stub System.setProperty("webdriver.chrome.driver", "C:\\work\\Selenium\\chromedriver_win32\\chromedriver.exe"); WebDriver driver = new ChromeDriver(); driver.get("https://www.google.com/"); driver.findElement(By.xpath("//input[@class='gLFyf gsfi']")).sendKeys("xxxxx"); driver.findElement(By.xpath("//div[@class='eIPGRd']/div")).click(); } } -

Download

0 formats

No download links available.

How to solve "Webdriver cannot be resolved to a type" Error in Selenium? | NatokHD