Easy way to deploy a windows service?

  • Thread starter Cory J. Laidlaw, Beyond01.com
  • Start date
C

Cory J. Laidlaw, Beyond01.com

I am trying to find an easy way to deploy my windows service (written in VB,
Visual studio 2008)

I have created my deployment project, and to the Service Project I added a
ServiceProcessInstaller and a ServiceInstaller by adding them to my toolbox
and then dragging them over to my main project. I then set all the properties
and told the serviceinstallers parent is the processinstaller. (note, I did
not add any code for these items)

I build the project, and get my output. I then run the setup program and it
creates the folders and installes the Executable under program files, but
does not install it as a service.(e.g. I can't see the service in the
Services control panel applet.)

I am sure I am doing somehting wrong here, but am clueless, and a newbie at
this.

Help is appreciated! Thanks!

Cory
 
S

sloan

I would look here:
http://www.eggheadcafe.com/articles/20041204.asp


Do not concentrate on the msmq or command pattern part.

Concentrate on Peter's slick way of having an install.bat and a
uninstall.bat for server installation.

(There are code changes you need to put in, not just create some .bat files)

But his method is the most easy I've ever seen.





"Cory J. Laidlaw, Beyond01.com"
 
C

Cory J. Laidlaw, Beyond01.com

Thanks sloan! I will check it out.

sloan said:
I would look here:
http://www.eggheadcafe.com/articles/20041204.asp


Do not concentrate on the msmq or command pattern part.

Concentrate on Peter's slick way of having an install.bat and a
uninstall.bat for server installation.

(There are code changes you need to put in, not just create some .bat files)

But his method is the most easy I've ever seen.





"Cory J. Laidlaw, Beyond01.com"
 
N

Nobody

"Cory J. Laidlaw, Beyond01.com"
I am trying to find an easy way to deploy my windows service (written in
VB,
Visual studio 2008)

I have created my deployment project, and to the Service Project I added a
ServiceProcessInstaller and a ServiceInstaller by adding them to my
toolbox
and then dragging them over to my main project. I then set all the
properties
and told the serviceinstallers parent is the processinstaller. (note, I
did
not add any code for these items)

I build the project, and get my output. I then run the setup program and
it
creates the folders and installes the Executable under program files, but
does not install it as a service.(e.g. I can't see the service in the
Services control panel applet.)

I am sure I am doing somehting wrong here, but am clueless, and a newbie
at
this.

Help is appreciated! Thanks!

If this is intended as in-house solution, you can use SC command line to
install or remove the service. If it's intended for general usage, then you
have to make an installer.

How to create a Windows service by using Sc.exe
http://support.microsoft.com/kb/251192

You install the service by using "Create" command, and you specify the file
name with "binpath" option. See CreateService() API function for detailed
description of some of the options. SC is included with Windows XP and
after. In prior versions you have to buy the resource kit. There maybe GUI
based software out there instead of using command lines. Off course, you
have to update the DotNet runtime version prior to that.
 
H

Herfried K. Wagner [MVP]

"Cory J. Laidlaw, Beyond01.com"
I am trying to find an easy way to deploy my windows service (written in
VB,
Visual studio 2008)

I have created my deployment project, and to the Service Project I added a
ServiceProcessInstaller and a ServiceInstaller by adding them to my
toolbox
and then dragging them over to my main project. I then set all the
properties
and told the serviceinstallers parent is the processinstaller. (note, I
did
not add any code for these items)

You'll find a step-by-step guide here:

How to create a Setup project for a Windows Service in Visual Basic .NET or
in Visual Basic 2005
<URL:http://support.microsoft.com/?scid=kb;EN-US;317421>
 

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