Hey I have an MSI, built with WiX, that attempts to specify a launch condition that is satisfied only when IIS is installed. This condition is not working as desired on WS2008 x64. It works on my Windows 7 x64 machine.
The property:
<!-- This is used later in a Launch condition. -->
<!-- see http://learn.iis.net/page.aspx/135/discover-installed-components/ -->
<Property Id="IIS7" Value="#0">
<RegistrySearch Id="IIS7W3SVC"
Type="raw"
Root="HKLM"
Key="SOFTWARE\Microsoft\InetStp\Components"
Name="W3SVC" />
</Property>
The condition:
<Condition Message="Cannot install. You must install IIS before installing this product.">
NOT IIS56 = "#0" OR NOT IIS7 = "#0"
</Condition>
(there is also a property for IIS6, but that should be irrelevant here).
A user is reporting that he is seeing this "cannot install" message. He also says that IIS is installed and functioning.
Does WS2008 have a different registry key for IIS presence?
What is the preferred mechanism to determine if IIS is present?
This is WIX 3.5. Not sure of the exact WS2008 version.
It might be similar to the issue described here. That question is unresolved.
ideas?
Why not just use the Wix IIS extensions and IISMAJORVERSION and IISMINORVERSION?
We use them and I know they work on every version of windows we've used from XP to 2008R2
<!-- Reference WixIIsExtension in project and pull in property by ref -->
<PropertyRef Id="IISMAJORVERSION"/>
<Condition Message="Install requires IIS 6 or 7.">
<![CDATA[Installed OR (IISMAJORVERSION AND (IISMAJORVERSION = "#6" OR IISMAJORVERSION = "#7"))]]>
</Condition>