J2ME Wireless Toolkit 1.0.3 Beta

I'm now using J2MEWTK 1.0.3 Beta to test my J2ME applications and it runs smooth, however I faced a problem when trying the OTA download.

After I ran the OTA (emulator -Xjam) and typed the correct location of my JAD files, it showed a list of applications I have on server, but when I've choosed one of the application and clicked "install", it asked me to check the JAD file. Can anyone help, thanks a lot.

Moreover, if I just click the JAD file on my PC, it can download the JAR file from server and run it.

[537 byte] By [ho_ming_tat] at [2007-9-26 5:14:07]
# 1

[ho_ming_tat],

Can you check your .jad (Java Application Descriptor file) on the emulator side and verify that the MIDlet-Jar-URL attribute points to the correct URL where the MIDlet suite .jar file that you want to have it OTA-ed over to the emulator.

An example of the .jad file, whereby http://www.MidletServer.com:8080 is the webserver that contains the jar file MyMIDlet.jar resides:

MIDlet-Version: 1.0

MIDlet-Vendor: Sun Microsystems, Inc.

MIDlet-Jar-URL: http://www.MidletServer.com:8080/deploy/MyMIDlet.jar

:

:

:

HTH.

Allen Lai

Developer Technical Support

SUN Microsystems

http://www.sun.com/developers/support/

allenlai at 2007-6-29 19:16:41 > top of Java-index,Java Mobility Forums,Java ME Technologies...
# 2

I stand corrected in my previous reply.

You must check the .jad file that resides ON THE WEB SERVER with the correct URL pointer attribute and also make sure the .jar file exists in the correct location.

Also you need to ensure that the MIME type on the webserver for .jad files is set and looks like this:

MIME=text/vnd.sun.j2me.app-descriptor

, so that the webserver returns the correct MIME type to the Java Application Manager on your emulator or J2ME device.

All you need to have in your MIDlet are lines of code that will open a HTTP connection to the HTML page on the webserver that contains a HREF tag pointing to .jad file that has the URL pointer attribute that points to the .jar MIDlet app file.

HTH.

Allen Lai

Developer Technical Support

SUN Microsystems

http://www.sun.com/developers/support/

allenlai at 2007-6-29 19:16:41 > top of Java-index,Java Mobility Forums,Java ME Technologies...
# 3
I've put both the JAR and JAD files in the same location, the MIDlet-URL has been set correctly, but I still cannot do the OTA download using J2MEWTK 1.0.3, however I can download and run those applications when I double clicked the JAD file, any suggestions? Thanks a lot!
ho_ming_tat at 2007-6-29 19:16:41 > top of Java-index,Java Mobility Forums,Java ME Technologies...
# 4

I've problems with this to....

I've done the following:

-add the proper mime type in the web server;

-made a html file containing links to the jar files (by the way, should this links be relatives or completes, meaning that pong/pong.jad or http://127.0.0.1/pong/pong.jad);

-in the jad file I have all mandatory and some optional attributes. The link to the jar file is complete (http://127.0.0.1/pong/pong.jar);

-run emulator -Xjam, write the http site and choose the pong link...

Nothing happen when I have relative paths, and some exception (InvalidJadException) is raised when I have complete path on my http file pointing to the jad file...

What should I do? Can anyone help me on this?

Thanks

Marco

Marco.Caetano at 2007-6-29 19:16:41 > top of Java-index,Java Mobility Forums,Java ME Technologies...
# 5

I've problems with this to....

I've done the following:

-add the proper mime type in the web server;

-made a html file containing links to the jar files (by the way, should this links be relatives or completes, meaning that pong/pong.jad or http://127.0.0.1/pong/pong.jad);

-in the jad file I have all mandatory and some optional attributes. The link to the jar file is complete (http://127.0.0.1/pong/pong.jar);

-run emulator -Xjam, write the http site and choose the pong link...

Nothing happen when I have relative paths, and some exception (InvalidJadException) is raised when I have complete path on my http file pointing to the jad file...

What should I do? Can anyone help me on this?

Thanks

Marco

Marco.Caetano at 2007-6-29 19:16:41 > top of Java-index,Java Mobility Forums,Java ME Technologies...