Skip to main content

MIDlet JAR File (error : Failed to load main-class manifest attribute .)

1 reply [Last post]
enas_ahmad5
Offline
Joined: 2008-09-07
Points: 0

hey all,
I`ev started learning J2ME and im using NetBeans IDE , my problem is that my projects run fine in the IDE but when i double-click the JAR file (that is automatically created by NetBeans ) or when i try to run it using the command line an error comes up which is :
Failed to load main-class manifest attribute from ..
but my project dosn`t have a main class (public static void main (String args[] )!!! it only have MIDlet class !!
please any thoughts ?!?
thanks

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
sfitzjava
Offline
Joined: 2003-06-15
Points: 0

you can not run midlets from double clicking on it, because the standard java classes used by JavaSE are different for JavaME. You will need to run it in the WTK using the Emulator.

Here is a link with information to help do this.
http://java.sun.com/javame/reference/docs/sjwc-2.0-web/docs/ToolsGuide-h...

-Shawn