Re: Service failure
- From: "J. Anos" <j@xxxxxxxx>
- Date: Tue, 12 Jun 2007 13:45:14 -0400
but he just said its not a service(?)
"Adam Sandler" <corn29@xxxxxxxxxx> wrote in message news:1181581089.055455.54020@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
On Jun 8, 9:56 pm, Rob <R...@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:The service is not a "typical service" in services.msc
It is a process named requestq - that you can see running in task manager.
This process sometimes dies.
As I mentioned earlier, there are a few ways to make this happen...
the really smelly but simple solution goes something like this:
Dim objNet : Set objNet = CreateObject("WScript.Network")
Dim sName : sName = objNet.ComputerName
Dim objWMI : Set objWMI = GetObject("winmgmts:\\" & sName &
"\root\CIMV2")
Dim objService : Set objService =
objWMI.Get("Win32_Service.Name='servicename'")
Do Until hellFreezesOver
If objService.State = "Stopped" Then
start = objService.StartService()
End If
WScript.Sleep 2000
Loop
Something a bit more elegant is monitoring your process
asynchronously. This link will get your started:
http://www.microsoft.com/technet/scriptcenter/resources/scriptshop/shop0805.mspx
.
- Follow-Ups:
- Re: Service failure
- From: Adam Sandler
- Re: Service failure
- References:
- Re: Service failure
- From: Adam Sandler
- Re: Service failure
- From: Adam Sandler
- Re: Service failure
- Prev by Date: Re: Serious HTA/CSS Help...
- Next by Date: Re: logoff/shutdown script
- Previous by thread: Re: Service failure
- Next by thread: Re: Service failure
- Index(es):