Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is a service Active or not?
Message
 
To
19/01/2007 16:09:18
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
MS SQL Server
Miscellaneous
Thread ID:
01187184
Message ID:
01187203
Views:
18
If the service isn't running you can try to start service with
isAllOk = oShellApp.ServiceStart("Here write the Service Name",.t.)
and to stop with
isAllOk = oShellApp.ServiceStop("Here write the Service Name",.t.)
for more info check http://msdn.microsoft.com/library/default.asp?url=/library/en-us/shellcc/platform/shell/reference/objects/ishelldispatch2/servicestart.asp


>Perfect, Thanks Vladimir.
>
>>Take a look at Message # 1180154
>>
>>>Hello,
>>>
>>>We have a windows service provided by another company and running on a given XP machine, but it stops sometimes and we want to check its status from a VFP application.
>>>
>>>Is it possible to know the Windows Service's status (Stopped or Active) with VFP Code? I guess we need to call an API function.
>>>
>>>Thanks
>>>
>>>Juan Carlos.
_______________________________________________________________
Testing displays the presence, not the absence of bugs.
If a software application has to be designed, it has to be designed correctly!
_______________________________________________________________
Vladimir Zografski
Systems Analyst
Previous
Reply
Map
View

Click here to load this message in the networking platform