Determining the Windows Installer Version
You can use the following methods to determine the Windows Installer version:
Call the MsiGetFileVersion function with the szFilePath parameter set to the path to the file Msi.dll.
You can call the SHGetKnownFolderPath function with the CSIDL_SYSTEM constant to get the path to Msi.dll. Beginning with Windows Vista, applications should use the SHGetFolderPath function and the REFKNOWNFOLDERID "System." Existing applications that use the SHGetFolderPath function and the CSIDL type will continue to work.
Applications can get the Windows Installer version by using DllGetVersion.
The installer sets the VersionMsi property to the version of Windows Installer that is run during the installation.
For more information, see Released Versions of Windows Installer.