winHandleBefore

  • Home
  • /
  • winHandleBefore
  • 04
    Oct

    Switching between tabs in Selenium

    Switching between tabs in Selenium   //Get handle to Current window tab. String mainWindowHandle = driver.getWindowHandle(); //Perform action which opens a new tab window in browser. //Get the list...

    Read More
  • 04
    Oct

    Switching between windows during script run

    String winHandleBefore = driver.getWindowHandle(); // Perform GUI action which opens a new window, use following code to switch to pop-up window: for (String currentWindow : driver.getWindowHandles()) driver.switchTo().window(currentWindow); to revert...

    Read More