He maha tonu pea ka hiahia koe ki te whakatuwhera i tetahi ripa hou ki te matapihi tirotiro ano o te ra kei te whakahaere i o whakamatautau SelDium WebDriver. Ma te kore e whakatuwhera he tirotiro hou, ka taea noa te whakamahi i te waehere i raro ake nei hei whakatuwhera i tetahi ripa hou i te tirotiro ano.
driver.findElement(By.cssSelector('body')).sendKeys(Keys.CONTROL +'t');
Ka whakatuwhera ana koe i tetahi ripa hou, me huri ki a ia kia taea ai te mahi me te ripa kua whakatuwheratia:
ArrayList tabs = new ArrayList (driver.getWindowHandles()); driver.switchTo().window(tabs.get(0));
Ko te waehere o runga ake nei he mahi ma te Tirotiro Firefox.
Panui atu: