What would the preferred way of programmatically determining which the currently installed version of Microsoft Internet Information Services (IIS) is?
I know that it can be found by looking at the MajorVersion key in HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W3SVC\Parameters.
Would this be the recommended way of doing it, or is there any safer or more beautiful method available to a .NET developer?