Reputation: 35
I have created a Swing GUI using NetBeans, and I am able to execute it on my local machine successfully. But whenever I execute the JAR file gui_test.jar
on another PC, it give me the error shown below.
The classes in the package gui_test
are:
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at gui_test.gui.walk(gui.java:967)
at gui_test.gui.<init>(gui.java:1030)
at gui_test.gui$17.run(gui.java:1030)
at java.awt.event.InvocationEvent.dispatch (Unknown Source)
at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.awt.EventQueue.access$000(Unknown Source)
at java.awt.EventQueue$3.run(Unknown Source)
at java.awt.EventQueue$3.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)
at jaya.awt.Eyentgueue.dispatchEyent(Unknown Source)
at jaya.awt.EyentDispatchIhread.punpOneEyentForFilters(Unknown Source)
at jaya.awt.EyentDispatchIhread.punpEyentsForFilter(Unknown Source)
at jaya.awt.EyentDispatchIhread.punpEyentsForHierarchy(Unknown Source)
at jaya.awt.EyentDispatchIhread.punpEyents(Unknown Source)
at jaya.awt.EyentDispatchIhread.punpEyents(Unknown Source)
at java.awt.EyentDispatchIhread.run(Unknown Source)
Any suggestions to resolve the problem will be appreciated.
Upvotes: 1
Views: 357
Reputation: 23025
Following are possible.
That's all I can think about. Try this in another few machines, which has the same Java version, then only you can get the issue.
Upvotes: 1
Reputation: 8708
I'm not too familiar with Netbeans, But I do recall having problem importing a GUI from Netbeans into eclipse. This is possibly because the Netbeans GUI uses certain libraries.
Check this question, and this answer, it might help you https://stackoverflow.com/a/4498151/975959
Upvotes: 0