0
String bknum=d.findElement(By.xpath(".//*[@id='error-back']/a[@style]")).getText();

List<WebElement> cols=d.findElements(By.xpath("//tbody/tr/td[2][text()]"));
System.out.println("Coloumn was selected");

for(WebElement col:cols){
    if(col.equals(bknum)){
        System.out.println("Bookng exists");
        d.findElement(By.xpath("//tbody/tr/td[2][contains(text(),"+bknum+")]/following-sibling::*[7]/a[2]/img")).click();
    }
4

0 回答 0