← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #280703]: How to get tooltip text inside image

 

Question #280703 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/280703

    Status: Answered => Open

sindhu is still having a problem:
Thanku sir.

I have consulted and got the solution but still I need help reagarding
how to compare two lists text:

//looping through span
Robot robot = null;
try {
	robot = new Robot();
	robot.mouseMove(550,638); 
	List<WebElement> elements =driver.findElements(By.xpath(ObjectRepository.tooltiptext));
    for(WebElement tooltiptextbeforeselection:elements)
    {
    System.out.println(tooltiptextbeforeselection.getText());
    }
  
} catch (AWTException e) {
	// TODO Auto-generated catch block
	e.printStackTrace();
}

robot.mousePress(InputEvent.BUTTON1_MASK);
robot.mouseRelease(InputEvent.BUTTON1_MASK);
List<WebElement> elements =driver.findElements(By.xpath(ObjectRepository.tooltiptext));
for(WebElement tooltiptextafterselection:elements)
{
System.out.println(tooltiptextafterselection.getText());
}

Please help me how to compare tooltiptextbeforeselection and
tooltiptextafterselection.

Thanks in advance.

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.