[Mono-list] Detect OS?

Immortal immortal at hackforums.net
Sat May 19 04:18:11 UTC 2012


Well Im writing some c# code, I would like to know how I would detect what OS
the user is running,

I dont want to use alot of if/thens

and I was hoping not to use a switch,

I was hoping for something simple as /Enviroment.GetOS();/

:P 

But I know about

*Enviroment.OSVersion.ToString().StartsWith("Unix");*

is their a faster and or easier way to get the users OS ?

--
View this message in context: http://mono.1490590.n4.nabble.com/Detect-OS-tp4645659.html
Sent from the Mono - General mailing list archive at Nabble.com.


More information about the Mono-list mailing list