General Question about JRE - Versions and backward compatibility etc

Could someone maybe help me with this query?

I've got a group of network users who use a total of four java applications which I am told require different versions of the Java Runtime Environment to run.

Is it therefore possible to have muliple versions of the RTE installed on one user machine to make all applications work at once or is it simply a case of having to have only one version of the JRE.

I'm talking mainly about in house applications so I guess if some of them are incompatible with the latest JRE then the answer might be to find out what the problem is and fix the application so it works in the lates jre - or am I missing something?

[682 byte] By [PiperAlphaa] at [2007-11-27 4:26:32]
# 1
Yes, you can have multiple versions of the JRE on one user system.
gymma at 2007-7-12 9:35:05 > top of Java-index,Desktop,Runtime Environment...
# 2

Hello,

First of all, it is possible to keep several JRE installed in Windows. For example, my PC has JRE 1.3.1.8, 1.4.0.1, 1.4.2.6.

Second. A tecnology exists to cause a Windowst to run a specific JRE for a specific Java applet. Please see the text below.

-

HTML Applet Configuration

?The standard (Internet) method of calling Java Runtime when using a Java Applet is to use an Applet tag within the HTML file itself specifying the applet details (example below). This tries to attach itself to Microsoft Java Runtime registry CLSID as detailed above.

<applet code=Applet1.class width="200" height="200">

Your browser does not support the <code>applet</code> tag.

</applet>

?When the above call is made either, a) the applet will load in the Microsoft Java Runtime, b) the applet will load in a particular Sun Java Runtime as it抯 being redirected or c) the applet won抰 load at all as Microsoft Java Runtime isn抰 installed and Sun Java isn抰 set as default.

?The above can be uncontrolled as to what version of Java (if any) is actually used to launch an applet so have an alternative solution is to us the Object tag in place of the Applet tag. It抯 only suitable for Internet Explorer in an internal, Intranet environment but should be ideal for us.

?By replacing the Applet HTML tag with the Object tag when loading an applet you can specify in the tag either to use the latest installed version of Sun Java or a specific version by putting it抯 CLSID in the list. (example below.)

<OBJECT

classid="clsid:CAFEEFAC-0014-0002-0006-ABCDEFFEDCBB"

width="200" height="200">

<PARAM name="code" value="Applet1.class">

</OBJECT>

?The advantage in the above approach is we can install a specific version of Java, i.e. 1.4.2.06 that doesn抰 redirect the Microsoft Java Runtime so won抰 effect other applications, and we can be safe in the knowledge that even if we install a newer version of Java on a machine that has 1.4.2.06 we won抰 have any backwards compatibility problems.

?The Object tag is an Internet Explorer only solution, but could be scaled, as to load a different version of Java you specify a different CLSID, whether that抯 one of the versions of Sun Java or Microsoft Java or you can specify a CLSID that covers the latest installed version of Sun Java if you don抰 want to tie the application to a specific version.

Further details on the use of the Applet and Object tags can be found on the Sun website below so they may be of use if the HTML code that calls the Java applet can be easily changed to support our requirements.

http://java.sun.com/j2se/1.5.0/docs/guide/plugin/developer_guide/using_tags.html

http://java.sun.com/products/plugin/versions.html

yakova at 2007-7-12 9:35:05 > top of Java-index,Desktop,Runtime Environment...
# 3
It's also worth reading this article as exact versions of the JRE are no longer supported, only "family" versions http://java.sun.com/javase/6/webnotes/family-clsid.html
johnnywintermutea at 2007-7-12 9:35:05 > top of Java-index,Desktop,Runtime Environment...