• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Dynamic Versioning using JRE version 1.5.0_09

 
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I have an applet window in my code. I want that applet to run only with JRE version 1.5.0_09 or higher. So i am using Dynamic Versioning. The code i am using is:

document.write('<OBJECT classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" codebase="1#Version=1,5,0,09" WIDTH="274" HEIGHT="72" >\n');
document.write('<PARAM NAME="type" VALUE="application/x-java-applet;jpi-version=1.5.0_09">\n');

Now the problem is that my applet is not running with version 1.5.0 or less but with versions like 1.5.0_06 its working fine. Any idea why??

Thanks,
Vivek.
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The latest Plugin Developers Guide no longer mentions the type attribute for the object tag, only for the embed tag. The Guide for 1.4 does, though. Strange.

Why is it that the applet should run on 1.5.0_09, but not on 1.5.0_06? They are API-compatible, after all.
[ December 22, 2006: Message edited by: Ulf Dittmer ]
 
Vivg Gupta
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Due to some latest standards,
�Sun Java Runtime Environment (JRE) - Establishes JRE version
1.5.0_09 and 1.5.0_10 as Mainstream/Standard across the Enterprise for running Java code on personal computers. Sun JRE version 1.5.0_06 and version 1.4.2_xx have been moved to the Retire/Contain phase of the TSS Technology Lifecycle.�

That's why i want to have the applet running only for the latest versions so that end users have version 1.5.0_09 or higher.

It would be great if you can tell me the solution so that the applet works only for the version 1.5.0_09 or higher.

Thanks,
vivek.
 
Ulf Dittmer
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If the applet failed to run on _06 due to some bug that _09/_010 fixed, I'm sure the users would tell you about it (and then they would be advised to upgrade the JVM). Until then, why worry? If corporate policy is to no longer use _06 at all, just tell the users/sys admins to uninstall it, and install the newer version. Why making the users (and your) life harder by preventing something that works?
 
Vivg Gupta
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thats fine but we need to implement the same so that the end users follow it strictly. That's why the applet should not run with version less than 1.5.0_09.

do we any solution for the same? I am not getting as to how the versions less than 1.5.0_09 are working.

Thanks,
Vivek.
 
author and iconoclast
Posts: 24207
46
Mac OS X Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Why not let the applet load, then check the "java.version" System property, and abort for versions you don't want to run under.
 
Vivg Gupta
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ya right. That seems to be a feasible solution. Thanks for the same.

But is there any specific reason why dynamic versioning is not working properly with version 1.5.0_09?
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Just ran into this myself. Figured out that java 1.5 is storing the version number as 5.x.x.x

so for jre 1.5.0_11-b03 instead of using :


use:


I checked in the registry to see what dll was being pointed to by the clsid, then browsed to the dll in windows, right click.. properties..
looked on the version tab
File Version shows: 5.0.110.3
Full Version shows: 1.5.0_11-b03

I never did find a link online with this answer. Seems like it would be in a few more places.
 
I am not a spy. Definitely. Definitely not a spy. Not me. No way. But this tiny ad ...
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic