LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Windows services

Solved!
Go to solution

Hi,

 

How programmaticlly get status of "A" Windows service?

Using "System Exec VI" was referred as a way to start/stop a service with proper command line text.

Is this VI the only solution? if yes, some detail how to ?

or any alternative?

 

David

0 Kudos
Message 1 of 3
(2,544 Views)
Solution
Accepted by topic author David1980

You can do it with .net

The example here lists all the services and its status. You can refer to msdn documentation for more details.

http://msdn.microsoft.com/en-us/library/system.serviceprocess.servicecontroller.status(v=vs.110).asp...


CLA CTAChampionI'm attending the GLA Summit!
Subscribe to the Test Automation user group: UK Test Automation Group
Message 2 of 3
(2,536 Views)

sc query servicename

 

Output example:

 

NOME_DO_SERVI€O: fax
TIPO : 10 WIN32_OWN_PROCESS
ESTADO : 1 STOPPED
CàDIGO_DE_SAÖDA_DO_WIN32 : 0 (0x0)
CàDIGO_DE_SAÖDA_DO_SERVI€O : 0 (0x0)
PONTO_DE_VERIFICAۂO : 0x0
AGUARDAR_DICA : 0x0

Message 3 of 3
(2,524 Views)