Identify the Operating System details in C#
The Environment class provides properties that can be used to obtain system information.
You can get OS information from System. Environment.OSVersion Here
Have a look at System.Environment It has property OSVersion