By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,536 Members | 2,165 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,536 IT Pros & Developers. It's quick & easy.

Windows Service idiot

P: n/a
I have two classes (thus, two services) in one Windows Service
executable. Each properly inherits from System.Process.ServiceBase,
and I have a ServiceInstaller for each service, and one
ServiceProcessInstaller for the entire executable, per the
documentation.

I can compile, and one service starts fine (the original one), but I
can't start the service I just added, and I get this error: "Could not
start the MyService service on Local Computer. Error 1083: The
executable program that this service is configured to run in does not
implement the service."

Huh?! I even copied the code from the first service to ensure it
wasn't a problem with the timer, etc.
Any clues? Thanks in advance for any help.

Jul 21 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Greg wrote:
I have two classes (thus, two services) in one Windows Service
executable. Each properly inherits from System.Process.ServiceBase,
and I have a ServiceInstaller for each service, and one
ServiceProcessInstaller for the entire executable, per the
documentation.

I can compile, and one service starts fine (the original one), but I
can't start the service I just added, and I get this error: "Could not start the MyService service on Local Computer. Error 1083: The
executable program that this service is configured to run in does not
implement the service."

Huh?! I even copied the code from the first service to ensure it
wasn't a problem with the timer, etc.
Any clues? Thanks in advance for any help.

For those keeping score, I found a solution:

In the Main sub of the first service class file (e.g. Service1.vb),
edit the auto-generated code as such:

ServicesToRun = New System.ServiceProcess.ServiceBase() {New Service1,
New Service2}

That does it! There's even some auto-generated comments that allude to
this. Now, each service appears in the services console and can be
started/stopped, etc. independently of one another.

Jul 21 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.