This is my first question, so I apologize for any mistakes. I will try to provide all the information I can. I basically wrote a simple swing application that just uploads an image to JPanel and displays it. I am using Netbeans 7.1 and I have the latest version of the Java SDK. Anyway, I used the "Build" feature in NetBeans 7.1 to deploy my application in a Jar file. When I double-click the Jar file on my PC, it works without problems. However, when I put it on other computers (I tested 2 more others, as with the current JRE itself), it does not open, citing the following error:
could not find main class: swong.Startup. Program will exit
swong is my package name, and Startup is my main method. I checked the manifest file that is created using the Netbeans assembly, and it [manifest] really contains the location of my main class of methods.
From the search, I ran into similar problems in which the class path is set incorrectly, but I do not understand how this can cause my specific error.
If someone could help me, I would be on the moon. I have been learning java for a year or so, and I have a good pen, but I NEVER could make a Jar that runs on a computer that was not my own. So, 10 points and thanks in advance.
jo.
EDIT: Thanks for the answers. I am doing shift work and lying around, but tomorrow I will check and shout out these answers and provide additional information. Thanks again. ho