Wednesday, March 11, 2009

Find Operating System name in Java

In order to find the name of Operating System in Java, there is a simple code :-

String os=System.getProperty("").toLowerCase();


{ System.out.println("It is Windows System");



{ System.out.println("It is a Unix System");



{ System.out.println("It is a Linux System");


Hope you found this useful!!

If you liked this article, please consider bookmarking or sharing it. Thanks!!

1 comment:

Write Your Comments..

Share this Page:-