How can i create a windows service for my application?

  • Thread starter Thread starter Lucian
  • Start date Start date
Hi,

If you are using VisualStudio.NET, then the GUI itself
provides much of the help for creating a Windows Service.
Well, you could do the following.
1. Click Files-New-Project
2. Now from the available project options on the right
hand side, choose "Windows Service"
3. Choose the default options, and click OK
4. Now add your code within OnStart method...

To install ur new service, within your Windows Service
project, add a new "Setup and Deployment Projects". Follow
the instructions from .NET help....

If you want to have a Windows Service without using any
Wizards or GUI, you could follow the sample within the
MSDN or .NET help documentation.

hth.
irfan
 
Careful when designing UI's to NT services, its a way to get privlidge
escallation.

If something runs as SYSTEM and then you have a UI popup that runs as that
USER, then you can inject messages into that window event queue, subclass
winproc's etc and get SYSTEM prilvlidges, always always be aware of that
when coding UIs to services etc.
 
ok, got it. Thanks for your help a lot.
-----Original Message-----
Careful when designing UI's to NT services, its a way to get privlidge
escallation.

If something runs as SYSTEM and then you have a UI popup that runs as that
USER, then you can inject messages into that window event queue, subclass
winproc's etc and get SYSTEM prilvlidges, always always be aware of that
when coding UIs to services etc.

--

Duncan McNutt
Microsoft Product Deactivation Team
--





.
 
Back
Top