I have two windows default, working on second window. Here I have clicked on some link which opens another window. Now I am trying to shift my focus to this opened window, but unable to focus it.
Initially I have taken
Set <String> obj1=driver.getWindowHandles(); which have two values. After clicking on link I have taken another set as
Set <String> obj2=driver.getWindowHandles();
In the for each loop I am adding the strings of the obj2 to obj1, if the obj2 is added then I am writing the code line as
driver.switchTo().window(obj2-- which is added) but I am getting error like this..
"Error message: org.openqa.selenium.WebDriverException: unknown error: DevTools returned unknown type:webview (Session info: chrome=43.0.2357.65) (Driver info: chromedriver=2.7.236900,platform=Windows NT 6.1 SP1 x86_64) (WARNING: The server did not provide any stacktrace information) Command duration or timeout: 9 milliseconds"
Can anyone help me out?