Java: NPE, when running jar on other system having sikulixapi.jar packed with the jar

Asked by shadab on 2016-01-11

I Installed sikulix in my system with option 2...i used the generated api to develop my selenium script....Then i exported my project into runnable jar file with all the external jars attached.....
Then i installed sikulix using 2nd option in another system...also using windows

and then i tried to run the exported jar file in the new system...But getting error :

 :Exception in thread "main" java.lang.reflect.InvocationTargetException...Caused by : java.lang.Null pointer Exception

Question information

English Edit question
Sikuli Edit question
No assignee Edit question
Last query:
Last reply:
RaiMan (raimund-hocke) said : #1

I guess this is a bug (I never tested this option).

- do not pack sikulixapi.jar with your app jar
- copy sikulixapi.jar to the other system to any place you like (must be same system type!)
- at runtime of your app jar have a pointer to sikulixapi.jar in your class path

RaiMan (raimund-hocke) said : #2

made it a bug

shadab (shadab1rizvi) said : #3

So sorry ..for a very basic question.....
How can i perform the last step....
-at runtime of your app jar have a pointer to sikulixapi.jar in your class path

i am running the jar file in cmd using the command : java -jar pathofjar

shadab (shadab1rizvi) said : #4

i just checked .....i can't run m own jar file using command prompt...but i am able to run it via eclipse ...whats the explaination ??

Can you help with this problem?

Provide an answer of your own, or ask shadab for more information if necessary.

To post a message you must log in.