one way is to stop at a break point and then right click and select evaluate expression. then type
System.getProperty("java.runtime.name") //will be something like "Java(TM) 2 Runtime Environment, Standard Edition"
System.getProperty("java.vm.version") //will be something like 1.4.1-b21
btw this is how i figured this out (just so I teach you how to fish :)
Properties p = System.getProperties(); Iterator i = p.keySet().iterator(); while(i.hasNext()){ String nxt = i.next().toString(); System.err.println("key is " + nxt + " and value is " + p.getProperty(nxt)); }
one way is to stop at a break point and then right click and select
evaluate expression.
then type
>
System.getProperty("java.runtime.name") //will be something like
"Java(TM) 2 Runtime Environment, Standard Edition" >
System.getProperty("java.vm.version") //will be something like 1.4.1-b21
> >
btw this is how i figured this out (just so I teach you how to fish :)
>
Properties p = System.getProperties(); Iterator i = p.keySet().iterator(); while(i.hasNext()){ String nxt = i.next().toString(); System.err.println("key is " + nxt + " and value is " +
btw this is how i figured this out (just so I teach you how to fish :)
Properties p = System.getProperties(); Iterator i = p.keySet().iterator(); while(i.hasNext()){ String nxt = i.next().toString(); System.err.println("key is " + nxt + " and value is " + p.getProperty(nxt)); }
I think an easier way to fish is: System.getProperties().list(system.out);
Or press ctrl-q on the "getProperties()" part for a list of system properties.
one way is to stop at a break point and then right click and select evaluate expression.
then type
System.getProperty("java.runtime.name") //will be something like "Java(TM) 2 Runtime Environment, Standard Edition"
System.getProperty("java.vm.version") //will be something like 1.4.1-b21
btw this is how i figured this out (just so I teach you how to fish :)
Properties p = System.getProperties();
Iterator i = p.keySet().iterator();
while(i.hasNext()){
String nxt = i.next().toString();
System.err.println("key is " + nxt + " and value is " + p.getProperty(nxt));
}
Thanks.
I wonder why do I see the Java version when I run (triangle icon) but not
when I debug (beetle icon)?
Amnon
"charles decroes" <spam@decroes.com> wrote in message
news:14073278.1057593697511.JavaMail.itn@is.intellij.net...
evaluate expression.
>
"Java(TM) 2 Runtime Environment, Standard Edition"
>
>
>
>
p.getProperty(nxt));
>
>
i get the same results on both if i do
System.err.println(System.getProperty("java.runtime.name"));
System.err.println(System.getProperty("java.vm.version"));
I am running an applet which kicks off the standard jdk. Are you debugging an applet, application or web component?
command line option
shows the version when the JVM starts.
charles decroes wrote:
I think an easier way to fish is:
System.getProperties().list(system.out);
Or press ctrl-q on the "getProperties()" part for a list of system
properties.
Bas
As always there is more than one solution to any given problem. i like your way better
This is the cleanest and easiest way.
Thanks!
"Peter Sch?fer" <peter.schaefer@healy-hudson.com> wrote in message
news:20229019.1057652671992.JavaMail.javamailuser@localhost...
>
>
>