Home > Not Find > Could Not Find Or Load Main Class Jar Command Line

Could Not Find Or Load Main Class Jar Command Line


My netbeans's project properties clearly sets testing2.hihi as my Main class and I have clean and build it which produces a .jar file in my dist folder. refering to the old main class or configuration). One more option to find out the error, try to open a command prompt (in windows) or a terminal (in linux/mac) and give this command java -jar your_jar.jar . If yes your Launch Configuration might be set up incorrectly (e.g. http://awendigital.com/not-find/the-system-cannot-find-the-path-specified-command-prompt.html

Count the characters - bit by bit! I googled, but I couldn't find a solution. (some people seem to have a similar problem, and it seems to be only them who can't run their .jar's; they uploaded them Crazy 8s Code Golf Why jitter continuous value in a scatterplot? share|improve this answer edited Aug 12 '15 at 13:08 Micah Stairs 1039 answered Sep 3 '12 at 15:29 Amila Chamikara 565 What?

Could Not Find Or Load Main Class Jar Command Line

I just want Eclipse to produce something that I can >>execute. Report message to a moderator Re: Program runs, but cannot export to JAR [message #250552 is a reply to message #250548] Thu, 10 January 2008 01:35 Eclipse User Originally more hot questions question feed lang-java about us tour help blog chat data legal privacy policy work here advertising info mobile contact us feedback Technology Life / Arts Culture / Recreation

java eclipse share|improve this question edited Dec 25 '11 at 13:33 asked Dec 25 '11 at 11:37 Acidic 2,39262664 Did you try to explicitly specify the main class ? Try changing this to the same java you have in path. Regex with sed command to parse json text Did Donald Trump say that "global warming was a hoax invented by the Chinese"? Could Not Find Main Class Jar Executable Not the answer you're looking for?

Still does not work. 3. Could Not Find Or Load Main Class While Executing Jar File I guess there is a java6 installed in my x86 folder. I meant to say that I have never > had any issues executing the program inside eclipse (by using the Run > As... internet And if this is not allowed, it would have been nice if Eclipse extracted the inner JARs.

Investigate the Class-Path line of MANIFEST.MF file. Could Not Find Or Load Main Class Jar Maven Further the JAR file contains the folders gui / guiDialogs / guiElements / guiHelp / gx / logic (contains Start.class) / META-INF / sounds and no other external JAR's. Program will exit up vote 2 down vote favorite I have a Java application developed with Eclipse. A jar file is not a text file.

Could Not Find Or Load Main Class While Executing Jar File

asked 4 years ago viewed 57527 times active 1 year ago Linked 130 Running JAR file on Windows 36 Loading image resource 25 “Could not find the main class” when double-clicking Discover More How to include multimedia files in beamer Do SSDs reduce the usefulness of Databases Output the first position in your program for each input character How can I turn rolled oats Could Not Find Or Load Main Class Jar Command Line woohoo... Error Could Not Find Or Load Main Class Jar Linux So I assumed I was running everything on my machine with 1.7.

On exporting the .JAR file in Eclipse, when I dclick the .JAR file it says "Could not find the main class: TempConversion.TempConversionMain. weblink Executing the jar file from and command line does not work, as I > showed with two quotes of trying to execute the jar from the command line. > So Eclipse you could echo %JAVA_HOME%, in cmd window to check this. tictactoe, and immediately after BeginGame press Enter and save the file. Jar Cannot Find Main Class

Just right click on the line that says "JRE System Library" next to an icon that resembles a stack of books, and click Properties. There is a folder with my package name, which contains all the .class files, including the class that contains the main method. Not the answer you're looking for? navigate here I just think that it has something to do with those two jar files which I included inside of the jar that I am trying to execute.

So, try to include correct manifest.mf into the jar. Could Not Find Or Load Main Class Jar Ubuntu EDIT4: I finally solved the problem. Thank you :) ApertureT3CH EDIT: okay guys, you're making me unsure here.

this was not the case) Jesper de Jong Java Cowboy Sheriff Posts: 15658 54 I like...

is it possible to edit this afterwards? –Valentino Ru Oct 19 '12 at 8:44 Yes, right click on a project open its Properties. share|improve this answer answered Apr 14 '12 at 1:16 haskovec 307311 No, no external jar's. –ApertureT3CH Apr 14 '12 at 6:22 add a comment| up vote 0 down vote Thanks for the initial intent in trying to help, g00se. Could Not Find Main Class Program Will Exit Executable Jar share|improve this answer edited Jan 25 '13 at 9:16 Sumit Singh 16k54180 answered Jan 16 '13 at 11:32 Waleed Madanat 864620 Thanks: I did not know about the "Export

I did not do anything special for that, I do not pass in any arguments. I don't really know what all this means. But the problem remains... :-( –DavideChicco.it Jan 16 '13 at 10:12 look for the ways to include .jar files in classpath , when running an executable jar file for http://awendigital.com/not-find/java-cannot-find-symbol-class.html C:\JarFile>C:\Oracle\Middleware1013\jdk160_18\bin\jar -tf PushupTimer.jar META-INF/ META-INF/MANIFEST.MF myTimer.class timeClock.class C:\JarFile>C:\Oracle\Middleware1013\jdk160_18\bin\jar -xf PushupTimer.jar META-INF/MANIFEST.MF Manifest-Version: 1.0 Created-By: 1.6.0_18 (Sun Microsystems Inc.) Main-Class: myTimer any ideas?

You still need to know how to write and package a Java application. share|improve this answer answered Jun 4 '12 at 4:49 Ted Hopp 167k28250355 1 Hi thanks alot! command and executing as a Java application). So I was compiling for 1.7, but trying to open as 1.6.

share|improve this answer answered Jul 7 '14 at 17:56 iowatiger08 1,2091222 add a comment| Your Answer draft saved draft discarded Sign up or log in Sign up using Google Sign Eclipse is a pretty good tool for writing Java code, but it is not an application generator. I'm having a little trouble understanding what is and isn't working. How should night time be determined and logged in a fast westbound plane?

This should resolve any issues. –Rakesh Mar 8 '12 at 7:31 add a comment| up vote 1 down vote Have you renamed your project/main class (e.g.