What is the difference between a windows service and a regular application?

I created only regular Windows applications (mostly C #). What distinguishes a Windows service from a regular Windows application? What makes them different? What can a service do that an application cannot do? What are the differences observed by developers? How do you create it? Is it easy to create a regular application (perhaps a Console application, since there is no gui?), And run or install it in a special way, or does it still need to be done?

+5
source share
4 answers

There are several things that jump out right away.

  • They run in a completely different console, starting with Vista li>
  • . , , . , - (, ) .
  • .
  • , ​​, , .
+9

MSDN , . , , .

, , , , . , , , . , .

1:1 . , svchost ( , , ). , .

# , , .

, - , HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services, " " ( ) , , , / .

+6

Unix, Windows Unix. - .

+2

, Windows - , . , .

Another advantage is that you can automatically start services when a user logs in.

There are also methods that you can override that are called when the service starts / stops (that is, from the | Administrative Tools | Services control panel).

Visual Studio has a special type of project that you can use to create it. See the website below: http://www.dotheweb.net/articles/dotnet/services.aspx

0
source

All Articles