0

i have some WIX code to install an application that also has a service to start. My problem is, i want it to still install even if there is a problem with the service starting.

i have tried using the "VITAL" attribute and setting it to "no" but this doesn't seem to work. below is my ServiceInstall Element code:

   <Component Id="PFME_Email2API_Service" Guid="{8990D911-BAD4-4d4d-9C38-779D11BF3F21}">

  <File Id="PFME_Email2API_Service.exe" Vital="no" Name="PFME-Email2API-Service.exe" KeyPath="yes" Source="C:\Wix Stuff\PFME-Email2API-Service\PFME-Email2API-Service\bin\Debug\PFME-Email2API-Service.exe"/>

      <ServiceInstall Id="InstallEmail2APIService" Vital="no" Name="testsvc" DisplayName="PFME Email2API Service" Start="auto" ErrorControl="normal" Type="ownProcess"/>

      <ServiceControl Id="sc_PFMEEmail2APIService" Name="testsvc" Start="install" Stop="both" Remove="uninstall" Wait="yes"/>
    </Component>
bandaa
  • 159
  • 3
  • 5
  • 11

1 Answers1

1

Perhaps the ServiceControl's Wait attribute needs to be set to "No"

How to install and start a Windows Service using WiX

Community
  • 1
  • 1
Rick Bowerman
  • 1,866
  • 12
  • 12
  • Setting wait="no" doesn't start any services at all now... even when there isn't an error with the service. – bandaa Apr 29 '14 at 09:20