I have created a Windows service with using that service. How will I call a Windows application?
-
2Ush, your question is not clear? Do you want to create a windows service using C#? Or are you asking how you can convert a stand alone app into a service? – bobbyalex Feb 22 '10 at 05:56
-
I am asking how to convert standalone app into a service – ush Feb 22 '10 at 06:04
-
1As stated, if you want help, you need to be more specific (and accept some answers to previous questions). – Bryan Feb 22 '10 at 07:50
3 Answers
Windows services and Windows applications are completely different programs. Windows services are automatically started when the computer boots, have no user interface and have different security context than logged in user. You can't simply convert a Windows application to a Windows service (and expect it to run smoothly). If you want your program to always run (24/7) with no user interface then you can look into Windows services.
More on Windows services: "Windows Service vs Windows Application - Best Practice" and "Windows Service Applications".
-
k fine .plz suggest me some more ideas how to run my application as service – ush Feb 22 '10 at 07:07
-
I have created windows application know i have to run this as a service plz tell me ur ideas – ush Feb 22 '10 at 07:12
You have to pick a Windows service from the project type in Visual Studio. If you meant how can you host an application as a Windows service, the only way to do this is to create a new project of type Windows Service and use the Process class.
You can then create an install class and then use installutil or alternatively, use sc
from the command line to install it.

- 30,738
- 21
- 105
- 131

- 25,943
- 66
- 198
- 303
Hey, you can easily run ANY application as Windows service with this utility - Application As Service by Eltima

- 1