Here is some code to get infomation about your Operating system via WMI
The Win32_OperatingSystem WMI class represents an operating system installed on a Win32 computer system. Any operating system that can be installed on a Win32 system is a descendent (or member) of this class. If the computer has multiple operating systems installed, this class returns only an instance for the currently active operating system.
I have given you most of the syntax from the Managed Object Format (MOF) code and includes all inherited properties. = class Win32_OperatingSystem : CIM_OperatingSystem
Amend to suit what you require.