🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: free.it.visual-basic
Article #3777

Win NT + Services

#3777
From: Hauguel Arnaud
Date: Tue, 26 Mar 2002 17:08
40 lines
2677 bytes
Hi

I've got a service on a Win NT Server running when Win NT Start ( Auto ) but
this one crash abnormaly when it want with no reason, Or stop ...

So i want to make an app who find the service in the service list, find if
this service is running, ( with a timer on 2 min for exemple with a
function ) and if not, set the service on START ( run it ) .

the Server run a Win NT4 + SP6 and i know the name of the service ( to do a
'findservice NameOfTheService' )

i need to know how to run a service ('Call StartService NameOfService')
                        How to Find his Status ( Stopped or Started )
                        How to Stop a Service too .

thank's for peoples who can help me !


Hauguel.Arnaud@wanadoo.Fr ou Arnaud_Hauguel@goodyear.com

----------------------------------------------------------------------------
--------------

Voila j'ai un service Win NT qui se lance au demarrage de windows mais celui
ci parfois bug et se ferme sans raison ...

enfin le tout est que je veux faire une appli qui verrifie si le service
tourne ( verification toute les 2 min par exemple avec un timer +
procedure )

puis si celui si est coup�, le relance ( donc service + Start )

cela tourne sous NT 4.0 SP6 et je connais le nom complet du service si cela
peut m aider ( par exemple une procedure du genre 'call StartService
NomDuService' )

enfin si quelqu'un peux m'aider sur les service et vb ... merci

Hauguel.Arnaud@wanadoo.Fr ou Arnaud_Hauguel@goodyear.com
Technical Details
Message-ID: <a7q9tt$ko9$1@wanadoo.fr>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!fr.clara.net!heighliner.fr.clara.net!opentransit.net!wanadoo.fr!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: f94ee,a0006239d35a86a1,start
X-Google-Attributes: gidf94ee,public
X-Google-Thread: 10b997,a0006239d35a86a1,start
X-Google-Attributes: gid10b997,public
X-Google-ArrivalTime: 2002-03-26 09:08:14 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!fr.clara.net!heighliner.fr.clara.net!opentransit.net!wanadoo.fr!not-for-mail
From: "Hauguel Arnaud" <Hauguel.Arnaud@wanadoo.fr>
Newsgroups: free.it.visual-basic,it.comp.lang.visual-basic
Subject: Win NT + Services
Date: Tue, 26 Mar 2002 18:08:04 +0100
Organization: Wanadoo, l'internet avec France Telecom
Lines: 45
Message-ID: <a7q9tt$ko9$1@wanadoo.fr>
Reply-To: "Hauguel Arnaud" <Hauguel.Arnaud@wanadoo.fr>
NNTP-Posting-Host: aste-genev-bois-102-1-2-20.abo.wanadoo.fr
X-Trace: wanadoo.fr 1017162493 21257 217.128.79.20 (26 Mar 2002 17:08:13 GMT)
X-Complaints-To: abuse@wanadoo.fr
NNTP-Posting-Date: 26 Mar 2002 17:08:13 GMT
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.50.4133.2400
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400