3

I am currently building a Windows Service with C# and I just can't figure out how to debug it.


I am building it and then registering with installutil:

> installutil MusicRepo_FileMonitor.exe

The Commit phase completed successfully.

The transacted install has completed.

And as you can see above, it is supposedly being registered successfully, but I can't find it in services.smc. I have also tried starting the service with net start [ServiceName] but it's telling me The service name is invalid. so I guess it's not finding it.


For the record, I'm on Vista and I'm developing the ws with .Net 3.5


[Update]

Solution

2
  • When you created the service, what was the service name information that you provided inside the properties of the service? Commented Apr 2, 2009 at 19:35
  • ServiceName: MusicRepoFolderWatcher Commented Apr 2, 2009 at 19:38

2 Answers 2

3

Try Task Manager and see if you see MusicRepo_FileMonitor.exe. If not, then the service is definitely not running.

Alternatively, in Visual Studio, Debug > Attach to Process, check show processes from all users, and see if its there.

Sign up to request clarification or add additional context in comments.

Comments

3

Upon further research, I realized that I had no Installer attached to the service, so the problem was now fixed by adding an Installer.

Here is the tutorial I used to add a Service Installer and so on.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.