I am using Selenium version 3.11, gecko driver v0.20 and Firefox version 59. I used the system.setproperty script but I'm still getting this error:
Exception in thread "main" java.lang.IllegalStateException: The path to the driver executable must be set by the webdriver.gecko.driver system property
I also tried this with Firefox v40. Please help me sort out this issue. Thanks.
The syntax i used is as follows : System.setProperty("webdriver. gecko.driver","C:\geckodriver.exe");