File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes how to detect the operating system in java Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Beginning Java
Reply Bookmark "how to detect the operating system in java" Watch "how to detect the operating system in java" New topic
Author

how to detect the operating system in java

sonia pandit
Ranch Hand

Joined: Apr 19, 2008
Posts: 137
Is there a way to tell whether the current platform is linux or windows?

Thanks,

Sonia
Anuj Prashar
Ranch Hand

Joined: Apr 15, 2008
Posts: 99

Try this . .


SCJP 5,SCWCD 5, RHCT
sonia pandit
Ranch Hand

Joined: Apr 19, 2008
Posts: 137
What is the return value in case of Linux and 2) in case of Windows.

Thanks

Sonia
Swastik Dey
Ranch Hand

Joined: Jan 08, 2009
Posts: 1195

You can probably use a s.o.p to check the return value.


Swastik
sonia pandit
Ranch Hand

Joined: Apr 19, 2008
Posts: 137
What is s.o.p?
Swastik Dey
Ranch Hand

Joined: Jan 08, 2009
Posts: 1195

Sorry about that,

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to detect the operating system in java