-1

Code trials:

import org.openqa.selenium.WebDriver;
import org.openqa.selenium.chrome.ChromeDriver;

public class SeIntro {

    public static void main(String[] args) {
        System.setProperty("webdriver.chrome.driver","C:\\Users\\ramak\\Downloads\\chromedriver_win32.zip.exe" );
        WebDriver driver=new ChromeDriver(); 
    }
}

Snapshot:

enter image description here

undetected Selenium
  • 183,867
  • 41
  • 278
  • 352

1 Answers1

0

chromedriver_win32.zip is a type file a format for compressed file archives, allowing packaging of multiple files and directories into a single file.

Where as System.setProperty() line expects the absolute path of the ChromeDriver binary executable.


Solution

You need to unzip the chromedriver_win32.zip and pass the absolute path of the ChromeDriver binary executable as follows:

System.setProperty("webdriver.chrome.driver","C:\\Users\\ramak\\Downloads\\chromedriver_win32\\chromedriver.exe" );
undetected Selenium
  • 183,867
  • 41
  • 278
  • 352