Reputation: 1412
A small Java applet [Edited: that might not even be the right word: this is JNLP] in a site I support is currently compiled for Java v1.7. As v1.8 becomes increasingly common, our users are getting warnings like Firefox's "This application would like to use a version of Java (1.7) that is not installed on your system. We recommend running the application with the latest version of Java on your computer." Is there some way we could rebuild our applet to try for the 1.8 Java first and only try for the older 1.7 if 1.8 isn't available, preferably without needing to ask the user in either case? (FWIW, I'm a very experienced developer, but a rather inexperienced Java developer.)
Upvotes: 1
Views: 900
Reputation: 5581
The applet can specify the version of java required using a line like this in the <resources>
section of the code:
<j2se version="1.7*">
The version number specified can either end with a number, and asterisk or a plus sign.
If your code should run fine on Java 7 or Java 8, then you'd want "1.7+" to indicate you're not that picky about it.
Upvotes: 1