Привет! Нужно во фрейм переключиться, но через wd.switchTo().frame("fssarmiframe"); не переключает, поэтому сделал через Action. Тоже падает, элемент по которому клик нужно сделать не находит, может переключение так и не произошло? т.к. Xpath корректный.
Падает где точка останова
protected void openCheckFLK() throws InterruptedException { Thread.sleep(3000); Thread.sleep(3000); Thread.sleep(3000); Thread.sleep(3000); // wd.switchTo().defaultContent(); //wd.switchTo().frame(wd.findElement(By.xpath("//iframe[@src='https://portal-dev.fss.local/fssarm/?']"))); // wd.switchTo().frame(wd.findElement(By.xpath("//div[@class='portlet-boundary portlet-boundary_48_ portlet-static portlet-static-end portlet-borderless portlet-iframe ']//iframe[@src='/fssarm/?']"))); WebElement myframe = wd.findElement(By.xpath("//*[@id=\"fssarmiframe\"]")); Actions actionWithYourFrame = new Actions(wd); actionWithYourFrame.moveToElement(myframe).build().perform(); myframe.click(); // wd.switchTo().frame(wd.findElement(By.xpath("//*[@id=\"fssarmiframe\"]"))); // wd.switchTo().frame("fssarmiframe"); // wd.switchTo().frame(0); // wd.findElement(By.xpath("//*[@id=\"ext-element-77\"]/div[3]")).click(); //div[@id='ext-element-88']//div[3] WebElement admflk = wd.findElement(By.xpath("//div[@id='ext-element-88']//div[3]")); // WebElement admflk = wd.findElement(By.xpath("//div[@id='ext-element-88']//div[@id='ext-element-106']")); Actions actionAdmFlk = new Actions(wd); actionAdmFlk.moveToElement(admflk).build().perform(); admflk.click(); Thread.sleep(3000); Thread.sleep(3000); wd.findElement(By.id("ext-element-79")).click(); Thread.sleep(3000); Thread.sleep(3000); wd.findElement(By.id("button-1323-btnInnerEl")).click(); }