Install windows service from code

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Does anyone have an example of how to install a windows service from .net
code. I've seen PInvoke versions, but it should be able to be done using
System.Configuration.Install.Installer as the InstallUtil does.
Thanks
 
Ant said:
Does anyone have an example of how to install a windows service from .net
code. I've seen PInvoke versions, but it should be able to be done using
System.Configuration.Install.Installer as the InstallUtil does.
Thanks

There's a walkthough in the SDK documentation.

You can drag/drop the installers into your service.


Actual install is done with the

installutil.exe

Utility provided w/the SDK.
 
Back
Top