How to get the version of Midlet in lwuit?

I have a jad file with the following description

MIDlet-Jar-Size: 404071
MIDlet-Jar-URL: test.jar
MIDlet-Name: test
MIDlet-Vendor: Vendor
MIDlet-Version: 1.0.1
MicroEdition-Configuration: CLDC-1.1
MicroEdition-Profile: MIDP-2.0
MicroEdition-test: test

How to get MIDlet-Versionthrough the code?

I tried System.getProperty ("MIDlet-Version"), but it returns null.

+3
source share
2 answers

From your subclass MIDlet

String version = getAppProperty("MIDlet-Version");

Extracted from:

http://www.developer.nokia.com/Community/Discussion/showthread.php?153128-MIDlet-Version

+5
source

System.getProperty ("MIDlet-Version") will only work in a midlet or call from an midlet instance.

+1
source

All Articles