c# windows service, how to install on different machine?

S

S Moran

so i can use installutil to install the service on the machine the service
was written on, but how can i take the EXE and install on another computer
that doesnt have installutil?

am i limited to the ms command line utilities that normally install exe's as
services?
 
P

Phil Wilson

Every setup tool I've ever seen has a way to install a service, and that
includes VS 2005 setup&deployment projects, so I'd start there.
 
C

Chris Mullins [MVP]

You could give your exe a "-install" command line argument.

.... at which point, it would go out and register itself as a service. No
trouble.

The Service class has everything you need to install / uninstall a service.
 
C

Chris Dunaway

so i can use installutil to install the service on the machine the service
was written on, but how can i take the EXE and install on another computer
that doesnt have installutil?

am i limited to the ms command line utilities that normally install exe's as
services?

If the target machine has the .Net framework properly installed, then
InstallUtil will be present there.

Chris
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top