sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #52477
[Question #683860]: Unable to click on Images when sikuli jar is integrated with eclipse.
New question #683860 on Sikuli:
https://answers.launchpad.net/sikuli/+question/683860
Trying to automate desktop application in MAC using 'sikulixsetup-1.1.3.jar' with Eclipse Neon.
I am trying to capture the spotlight icon and want to click on it. Below is the code snippet. My maven project hierarchy is
/Users/ABC/Desktop/EclipseWorkspace/com.apttus.sikuli.test
Images are stored under the same project hierarchy.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
package com.apttus.sikuli.test.com.apttus.sikuli.test;
import java.io.File;
import org.sikuli.script.FindFailed;
import org.sikuli.script.ImagePath;
import org.sikuli.script.Screen;
public class SikuliTrialSpotlight {
public static void main(String atgs[]) throws InterruptedException {
Screen s = new Screen();
try {
System.out.println(ImagePath.getBundlePath());
//Thread.sleep(500);
System.out.println("User Directory");
System.out.println(System.getProperty("user.dir"));
s.find("SpotlightIcon.png");
s.click("SpotlightIcon.png");
s.wait("Spotlight_input.png");
//s.type(null, "hello world\n", 0);
} catch (FindFailed e) {
e.printStackTrace();
}
}
}
Whenever, I try to run the code, its throwing error :
/Users/sayanisengupta/Desktop/EclipseWorkspace/com.apttus.sikuli.test
User Directory
/Users/sayanisengupta/Desktop/EclipseWorkspace/com.apttus.sikuli.test
FindFailed: SpotlightIcon.png: (80x52) in S(0)[0,0 1680x1050] E:Y, T:3.0
Line 2761, in file Region.java
at org.sikuli.script.Region.wait(Region.java:2761)
at org.sikuli.script.Region.find(Region.java:2326)
at com.apttus.sikuli.test.com.apttus.sikuli.test.SikuliTrialSpotlight.main(SikuliTrialSpotlight.java:21)
--
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.