Does anyone know how to create a JAR file using JCreator ? i have try to create it but it gives me this error " Failed to load Main-Class manifest attribuite from c:\hello\.jar" which i doesn't know how solve it.

Recommended Answers

All 3 Replies

check the documentation of the jar command.
If you insist on using an IDE to prevent you from learning the language and its tools use its documentation as well.

Member Avatar for iamthwee

You need to create a manifest file yourself.

Open up a notepad file and in it type:

Main-Class: Yourmainclass.withoutthedotextension

Then save it as

MANIFEST.MF

This may not work though. Your best chance would be to jar it up from the command line, which I found to be the best solution.

I know JBuilder and ANT (and JBuilder uses ANT for it) can generate the manifest for you if you tell them the required information (like the main class...).
Comes in handy when you want an ANT script that does everything from compiling to testing to building your distribution archives.
RTFM to find out how.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.