Solved

How do I detect the jdk version a user has installed?

Posted on 2004-08-18
3
524 Views
Last Modified: 2012-05-05
Hi
I have a java class that needs to have jdk2 to run how do I detect this is available and if not take user to the java download page? If there is not a workable asp way to do this perhaps I could use a combination of javascript and asp.

Thanks
0
Comment
Question by:caddworx
3 Comments
 
LVL 5

Accepted Solution

by:
cristy56 earned 500 total points
ID: 11828859
Not too sure if this could help, take it as a reference :

String strVersion = System.getProperty("java.version");
String strRequired = "1.3.1";
         
if (strVersion.compareTo(strRequired) < 0) {
   String str = "WARNING: ....blabla .. run
           with a " +strRequired+" or higher
           version Virtual Machine!!!\nYou
           should install a new Runtime
           Environement.\nLook at
           http://java.sun.com .";

      ErrorDialog d = new ErrorDlg(str);
          d.setVisible(true);
                              System.exit(1);


nil_dib

----------------------------------
Cristy
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

I would like to start this tip/trick by saying Thank You, to all who said that this could not be done, as it forced me to make sure that it could be accomplished. :) To start, I want to make sure everyone understands the importance of utilizing p…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now