×

Discussion Board

Results 1 to 10 of 10
  1. #1
    Regular Contributor
    Join Date
    Dec 2009
    Posts
    59

    Auto-increment version

    Hello,

    I'm trying to auto increment the version for a j2me application, can anyone help me to do that ?

    Thanks.

  2. #2
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: Auto-increment version

    You mean, each time you build? You would need to add this to your build script,in which case it depends on how you're building your application. So, this is really an Ant question (if you're using Ant) rather than a J2ME question.

    As a rule, I'd avoid doing this, because some devices have problems displaying long version numbers (by "long", I mean something like "5.0.1014"). Where possible, keep each component of the version number to one digit for maximum compatibility.

    Graham.

  3. #3
    Regular Contributor
    Join Date
    Dec 2009
    Posts
    59

    Re: Auto-increment version

    Is the script the same for j2me as it is for j2se ? Cause i can't really find anything on j2me, that's why i tried asking here.

  4. #4
    Super Contributor
    Join Date
    Apr 2007
    Posts
    2,708

    Re: Auto-increment version

    on several IDE's there are inbuilt options for auto-incrmeent...
    In NetBeans for example you can select the Project properties -> General -> activate the "Automated Application Version Incrementation"

  5. #5
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: Auto-increment version

    Ah! That's useful! Thanks Tiger!

    Building Java ME is essentially the same as building any kind of Java, just with an extra step (preverification). So, doing this with ME is the same as SE.

  6. #6
    Super Contributor
    Join Date
    Apr 2007
    Posts
    2,708

    Re: Auto-increment version

    But as Graham mentions you will be getting long version numbers like :
    0.1.65

  7. #7
    Regular Contributor
    Join Date
    Dec 2009
    Posts
    59

    Re: Auto-increment version

    Thanks for the replies, but this is not what i'm looking for. When you install an application on your phone, it gives you a version, it's always 1.00 for me. I can change that in netbeans (General Attribute for JAR) but i can't get it to auto-increment.

  8. #8
    Regular Contributor
    Join Date
    Dec 2009
    Posts
    59

    Re: Auto-increment version

    I got it, i wrote ${deployment.number} before, but i didn't had the auto-increment option checked.

    So, again for everyone, in NetBeans:
    Properties on your project -> General -> Check "Automated Application Version Incrementation"
    Properties on your project -> Application Descriptor -> Set MIDlet Version to ${deployment.number}

    You have to build your application for the version to increment, just running it won't do.

    Thank you !

  9. #9
    Super Contributor
    Join Date
    Apr 2007
    Posts
    2,708

    Re: Auto-increment version

    lol,
    sorry my bad I forgot that second part :P

  10. #10
    Regular Contributor
    Join Date
    Jun 2009
    Location
    Tel-Aviv Israel
    Posts
    410

    Re: Auto-increment version

    Eclipse actually implements this very efficiently it updates the version every new Jar you generate and if you change the version manually in the manifest, it updates it from that version on...
    Thanks,
    Adam Zehavi.

Similar Threads

  1. [moved] Problems during the installation of a new version.
    By NikolaN in forum Symbian Signed Support, Application Packaging and Distribution and Security
    Replies: 10
    Last Post: 2009-06-18, 11:25
  2. Can someone please explain version system ?
    By carlosl in forum Symbian
    Replies: 7
    Last Post: 2009-06-12, 09:12
  3. Auto Call sis for 7650
    By tonzeh in forum Symbian
    Replies: 1
    Last Post: 2004-06-11, 04:25
  4. Auto Call sis for 7650
    By tonzeh in forum Symbian Tools & SDKs
    Replies: 0
    Last Post: 2004-06-10, 10:11
  5. setting of Series 60 MIDP SDK for Symbian OS version 1.2 for networking
    By servigo in forum Mobile Java Networking & Messaging & Security
    Replies: 2
    Last Post: 2003-07-31, 07:47

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×