<div class="gmail_quote">On Mon, Feb 15, 2010 at 18:17, Alf P. Steinbach <span dir="ltr"><<a href="mailto:alfps@start.no">alfps@start.no</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
* News123:<div class="im"><br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Hi,<br>
<br>
<br>
What is the best way with python to get a list of all windows services.<br>
<br>
As a start I would be glad to receive only the service names.<br>
<br>
However it would be nicer if I could get all the properties of a service<br>
as well.<br>
<br>
Thanks for any info and bye<br>
</blockquote>
<br></div>

<br>
* Registry functions:<br>
<br>
  Otherwise, I'd use the general registry access functions.<br>
<br>
  Info about the registry access functions is available in your Python docs.<br>
<br>
  All the information about services is in the Windows registry (documented in<br>
  the MSDN Library, which is available in a browsable on-line version at<br>
  Microsoft).<br>
 </blockquote><div>As for doing this via the registry, take a look at the EnumKey and EnumValue functions of the winreg module (_winreg in 2.x). HKLM\System\CurrentControlSet\Services contains service information, and iterating over that should get a lot of what's needed.</div>
</div>