Saturday, March 28, 2009

Creating and Installing a Windows Service with Visual Studio 2005

Creating and installing a windows service is explained step by step.

· Open Visual Studio 2005

· Select new project Visual C# - Windows in Project Types and Windows service in the installed templates and click Ok.

· Write the code for OnStart and OnStop. Build and see that the windows service does not have any errors.

· Run InstallUtil /i WindowsService.exe in the Visual Studio command prompt. To uninstall we can use InstallUtil /u WindowsService.exe.

· Open Services.msc and locate the service in the list of the services. Start the service.


by Uday Denduluri

No comments:

Post a Comment