System.getProperty(os.name); Check the getProperties() method of the System class for all the Properties that you can get.
[This message has been edited by Cindy Glass (edited February 07, 2001).]
"JavaRanch, where the deer and the Certified play" - David O'Meara
Joined: Dec 28, 2000
Can I do this using Java script too. when I am trying to use this in different browsers different results are retrieved. ie when i am running the applet where i use getproperties in IEexplorer i get WindowsNT 4 & when i use Netscape it gives back WinNT only . So is there a consistant way where I can the OS .
Joined: Sep 29, 2000
You are a bit at the mercy of the browser as to how they implement the JVM specifications. The only thing that you know is that IE will give consistant responses and Netscape will give consistant responses, each in their own special way.