Unable to launch IE browser in selenium webdriver -
i have written sample code launch ie browser
, load google page.
public class sample { public static void main(string[] args) { // todo auto-generated method stub system.setproperty("webdriver.ie.driver","h:/iedriverserver.exe"); webdriver driver=new internetexplorerdriver(); driver.manage().window().maximize(); driver.manage().timeouts().implicitlywait(10,timeunit.seconds); driver.get("http://www.google.com"); } }
but when run script launches browser , gets closed (less 2 sec) without prompting error , script wont terminates.
this can see on console screen:
started
internetexplorerdriver
server (32-bit)2.53.1.0
listening on port 46974
only local connections allowed
can 1 me on issue?
below steps worked me, hope work well:
- open internet explorer.
- navigate tools->option
- navigate security tab
- now option internet,intranet,trusted sites , restricted site enable "enable protected" mode check-box.
- set ie zoom level 100%
- click on apply , ok
- close ie browser , run script
Comments
Post a Comment