How to create jar

11 messages - 1283 views

Hi, I can run examples in the emulator, but dont know how to create jar files to install into the device.

Any help please.

The create package command leads to some errors

It depends on you IDE. Which on do you use ?

I am using eclipse with the eclipseme plugin

The best way would be to follow this link. (Section : Packaging your MIDlet for deployment)

Hi, I already tried that, but get errors like " jar executable not found ", " this feature needs full JDK installation",  etc.

Also, I guess there should be a special kuix.jar and kutil.jar for deployment, other than the ones used to run the examples in the emulator? (wich I am using actually)

kuix.jar or kutil.jar are library jars. In this case, you can use it only in development phase, but it is not your problem there.

To build a J2ME project you need to install the JDK, and the WTK. After that, report to the previous link if you use Eclipse with EclipseME, to configure all of this and it should work.

Hi, I reinstalled jdk and can now compile non kuix midlets that run on device.

Unfortunatly, for kuix midlets, i can produce jar file, but when i try to install it on device (nokia 7710 : midp2, cldc 1.1) i get the error message "invalid archive".

I think I am close to get your fantastic tool to work, but for now I am stuck with this problem.

Are you sure that you have defined MIDlets in your JAD file ?

If you use EclipseME, open the .jad file, switch on the Midlet tab, press add button.

Hi, in my example there are 2 jads one newly created in the deployed folder I think its correctly configurated, but I only upload the jar file to the device (thing that always worked for standard midlets, no need for jad).

But, if correctly understand I need to upload jad also for kuix midlets?

First, if you modify a Jad, change only the one at the root of the project (outside the deploy folder). The Jad inside the deploy folder is an autogenerated file.

Else, it's right that in your case copying the jad file to your phone is not needed, because its informations are copied in the jar manifest file on build time.

Then only be sure you have set a MIDlet in the project Jad file.

Hi, I followed your advice and it worked fine now, thanks.:)