Running NT Applications As Services

N

Thread Starter

Niall Watson

Dear List

Can anyone advise on the feasibility of running NT applications (created in either VB or VC), as a system Service . None of my reference books mention this.

Many thanks in advance

PES Automation Ltd (UK)
[email protected]
 
N

Niall Watson

I think most small applications can be run as a service. I have seen utilities specifically for this purpose. It was a while back so I can't
provide the names etc. I don't think this will be a problem at all.

Russ Bilbey
 
M
Here it is:

To get the complete article write to m[email protected] an empty message
with the subject: Q137890

>From Microsoft Knowledge Base:

Q137890

HOWTO: Create a User-Defined Service

--------------------------------------------------
The information in this article applies to:

Microsoft Windows NT Workstation versions 3.51, 4.0
Microsoft Windows NT Server versions 3.51, 4.0

--------------------------------------------------
IMPORTANT: This article contains information about editing the registry. Before you edit the registry, make sure you understand how to restore it if a problem occurs. For information on how to do this, view the "Restoring the Registry" or the "Restoring a Registry Key" online Help topics in Registry Editor.

SUMMARY
The Windows NT Resource Kit provides two utilities that allow you to create a Windows NT user-defined service for Windows NT applications and some 16-bit applications (but not for batch files).

Instrsrv.exe installs and removes system services from Windows NT and Srvany.exe allows any Windows NT application to run as a service.

===== continued...

Meir Saggie
 
R
The Windows NT Resource Kit contains utilities which can be used to configure Apps to be run as a service.

Rick Hudson
 
B
Look in:
http://www.winfiles.com/
http://www.geocities.com/SiliconValley/6591/howto.htm
http://www.ntfaq.com/
http://www.jsiinc.com/reghack.htm
http://www.bhs.com/newtech/
for general information on NT. You'll probably find your
answer in at least one location.

Brian Lawry, Mfg Software Engineer
Compressor Controls Corporation
[email protected]
www.compressorcontrols.com


>I think most small applications can be run as a service. I have seen
>utilities specifically for this purpose. It was a while back so I can't
>provide the names etc. I don't think this will be a problem at all.
>Russ Bilbey
 
G
Hello Niall,

To run as an NT service, an application requires specific entry points within the load module which will be invoked from the services control
manager (SCM). A native NT service application can easily be created in VC, but I'm not sure about VB.

If you already have an EXE that you wish to run as an NT service (created with VC or VB), there is a utility available from the Windows NT Resource kit that basically provides the hooks required by the SCM, and just spawns the EXE as a child process. The utility is called "srvany.exe".

Gord...

==============================================
Gord Ellis, P. Eng.
Northern Dynamic Inc.
J103-155 Frobisher Drive
Waterloo, Ontario
Canada N2V 2E1
Tel/Fax: (519) 725-2071/2072
web: www.nordyn.com
 
Top