I have created a swing application under windows enviroment using netbeans. It works perfectly fine when I double click the jar file. Then I moved my source code under linux machine /home/userrig/temp/testing.jar. If I chane my dir to cd /home/deo/temp and start executing jar like , swing application starts executing. But if I try to start the swing application under /home like , I get the error as follows.
Do I have to set the path for this jar instance? How do I proceed. Next question is whether to go KDE or GNOME for icon creation. I have just started reading about them. Or writing any batch script is enough to start the application. Thanks.
I think probably there's a hardcoded path or something in the testing.testing.createGUI(testing.java:200)
If you can provide the code for that method, maybe someone here can help.
SCJP 5.0, SCWCD 1.4, SCBCD 1.3, SCDJWS 1.4
Joined: Jan 13, 2008
Thanks. I developed the application in netbeans and then deployed the jar file in linux using ssh and tested it. I always went for "clean and build" option in netbeans to create jar file. I just now noticed that I get the same nullpointerexception if I try to do "run Project" in netbeans. I have not harcoded any where in the application. My main method is as follows
createGUI is a method which instantiates all the swing components and so on. Is there anything to do with netbeans properties?
That's very strange. It could be that some of the NetBeans' project config files are corrupted. Can you try to create a new Project in NetBeans and copy over all the source files and build them again.
Joined: Jan 13, 2008
I figured it out. Since I am reading some info from a config.properties file, I had to put a copy of config file from where I can launch my jar file. Once it is done, I am able to lauch from
So teh config.properties file has to be in the directory from where the application can be launched or is tehre any other way to handle this situation?
My next goal is to create an icon on linux desktop so that if the user wants to open the application, just a double will do. Any reading material to start with? Thanks. [ May 08, 2008: Message edited by: Gopu Akraju ]