The Environment.OSVersion
property can be used to get the version of the current OS. What value can its Version
property have for the various OSes out there?
I'm interested only in the Major
and Minor
values and primarily about desktops OSes.
Have a look at MSDN: Operating System Version