<HTML><HEAD></HEAD>
<BODY dir=ltr>
<DIV dir=ltr>
<DIV style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt">
<DIV>Hi all on the list.</DIV>
<DIV> </DIV>
<DIV>The following question is regarding an error that raises when i try to
execute this script:</DIV><PRE><SPAN class=kn>import</SPAN> <SPAN class=nn>_winreg</SPAN>
<SPAN class=kn>import</SPAN> <SPAN class=nn>wmi</SPAN>
<SPAN class=n>r</SPAN> <SPAN class=o>=</SPAN> <SPAN class=n>wmi</SPAN><SPAN class=o>.</SPAN><SPAN class=n>Registry</SPAN> <SPAN class=p>()</SPAN>
<SPAN class=n>result</SPAN><SPAN class=p>,</SPAN> <SPAN class=n>names</SPAN> <SPAN class=o>=</SPAN> <SPAN class=n>r</SPAN><SPAN class=o>.</SPAN><SPAN class=n>EnumKey</SPAN> <SPAN class=p>(</SPAN>
<SPAN class=n>hDefKey</SPAN><SPAN class=o>=</SPAN><SPAN class=n>_winreg</SPAN><SPAN class=o>.</SPAN><SPAN class=n>HKEY_LOCAL_MACHINE</SPAN><SPAN class=p>,</SPAN>
<SPAN class=n>sSubKeyName</SPAN><SPAN class=o>=</SPAN><SPAN class=s>"Software"</SPAN>
<SPAN class=p>)</SPAN>
<SPAN class=k>for</SPAN> <SPAN class=n>key</SPAN> <SPAN class=ow>in</SPAN> <SPAN class=n>names</SPAN><SPAN class=p>:</SPAN>
<SPAN class=k>print</SPAN> <SPAN class=n>key</SPAN></PRE><PRE><SPAN class=n></SPAN> </PRE>
<DIV>and this is the error message it give me:</DIV>
<DIV> </DIV>
<DIV>Traceback (most recent call last):</DIV>
<DIV> File "C:\Python27\wmitest8.py", line 7, in <module></DIV>
<DIV> sSubKeyName="Software"</DIV>
<DIV> File "C:\Python27\lib\site-packages\wmi.py", line 431, in
__call__</DIV>
<DIV> handle_com_error ()</DIV>
<DIV> File "C:\Python27\lib\site-packages\wmi.py", line 241, in
handle_com_error</DIV>
<DIV> raise klass (com_error=err)</DIV>
<DIV>x_wmi: <x_wmi: Unexpected COM Error (-2147352567, 'Ocurri\xf3 una
excepci\xf3n.', (0, u'SWbemProperty', u'Los tipos no coinciden ', None, 0,
-2147217403), None)></DIV>
<DIV> </DIV>
<DIV>I’m on a win7 machine, python 2.7 installed, and win32 library
installed.</DIV>
<DIV> </DIV>
<DIV>what i’m trying to do is to get the installed software on the machine, but
not with the Win32_Product, because the list it posts seems incomplete, not all
the installed software is on that list.</DIV>
<DIV> </DIV>
<DIV>Thanks in advance for the help you can privide me.</DIV>
<DIV> </DIV>
<DIV>Carlos Fuentes</DIV></DIV></DIV></BODY></HTML>