I have an existing Windows service (based on C #) that is derived from the installer class , and currently I use the MS supplied InstallUtil command line to install it and remove it. This works great, and as part of my system, I connected event handlers to the AfterUninstallEventHandler and CommittedEventHandler events. In my case, I just use them to write messages to the user event log - showing the dates and times of installation and uninstallation, as well as the version of programs.
I'm currently experimenting with Wix v3.5 Beta 1 to pack a bunch of my stuff, including this service, and I'm using Wix ServiceInstall and ServiceControl to replace what I did manually with InstallUtil.
However, Wix seems to use a completely different mechanism for InstallUtil to install services. This can be seen from the name and description of the service that Wix manages (unlike what was built into the service program), and that my events no longer fire (which, if another installation mechanism is used, I doubt that they are).
So, is it possible for Wix to complete the installation of the service in the same way as InstallUtil, or am I just going to come to terms with the differences?
Edit
Christopher suggested telling about service-related definitions from my code and transferring them to the Wix installer project. This bothers me, because now I either need to find a way to exchange information between two separate systems (which I have no idea how to share between code and Wix projects), or put up with defining information in two different places (very bad software).
source
share