I'm trying to check if a service exists on a remote machine using the Microsoft.Sdc.Tasks.ServiceProcess.ControlService
task.
<ControlService MachineName="$(TargetMachineName)" Action="Exists" ServiceName="w3svc">
<Output PropertyName="W3ServiceExists" TaskParameter="ServiceExists" />
</ControlService>
When I use the above task declaration I get this output from MSBUILD.
(42,54): error MSB4065: The "ServiceExists" parameter is not marked for output by the "ControlService" task.
Is there a way to use the ControlService class to get whether or not a service exists on a remote machine?