Can´t include sikuli in java

Asked by Thomas Maier

Hi

I tried to compile my prog in a 32-bit Windows 7 System. But now I get other errors.
 My source code:
import edu.mit.csail.uid.*;

public class sikuli{

    public static void main(String[] args) {

     Screen s = new Screen();

     try{
      System.out.println("Test");

      s.click("/img/test.png", 10);
     }
     catch(FindFailed e){
      e.printStackTrace();
     }

    }

}

The error code looks now like this:

java.lang.ExceptionInInitializerError
 at edu.mit.csail.uid.Region.findNow(Region.java:520)
 at edu.mit.csail.uid.Region.wait(Region.java:228)
 at edu.mit.csail.uid.Region.find(Region.java:186)
 at edu.mit.csail.uid.Region.getLocationFromPSRML(Region.java:573)
 at edu.mit.csail.uid.Region.click(Region.java:297)
 at test.main(test.java:26)
Caused by: java.lang.NullPointerException
 at com.wapmx.nativeutils.jniloader.DefaultJniExtractor.extractResource(DefaultJniExtractor.java:93)
 at com.wapmx.nativeutils.jniloader.DefaultJniExtractor.extractJni(DefaultJniExtractor.java:81)
 at com.wapmx.nativeutils.jniloader.NativeLoader.loadLibrary(NativeLoader.java:43)
 at edu.mit.csail.uid.Finder.<clinit>(Finder.java:16)
 ... 6 more

Thanks for your help

Thomas

Question information

Language:
English Edit question
Status:
Solved
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Solved by:
Thomas Maier
Solved:
Last query:
Last reply:
Revision history for this message
Thomas Maier (wang-liquin) said :
#1

Ok I got the solution for both problems I have. For the 64-bit Problem you have to install the jdk 32bit.
The problem which is described at this topic is the solution to copy the siculi-script.jar in your libs folder.

Revision history for this message
Thomas Maier (wang-liquin) said :
#2

Ok I got the solution for both problems I have. For the 64-bit Problem you have to install the jdk 32bit.
The problem which is described at this topic the solution is to copy siculi-script.jar in your libs folder and than integrate the lib.