python-win32-requ...@python.org wrote:
Send python-win32 mailing list submissions to
python-win32@python.org
To subscribe or unsubscribe via the World Wide Web, visit
http://mail.python.org/mailman/listinfo/python-win32
or, via email, send a message with subject or body 'help' to
python-win32-requ...@python.org
You can reach the person managing the list at
python-win32-ow...@python.org
When replying, please edit your Subject line so it is more specific
than "Re: Contents of python-win32 digest..."
Today's Topics:
1. get installed software remote machine (pacopyc)
2. Re: get installed software remote machine (Tim Golden)
----------------------------------------------------------------------
Message: 1
Date: Fri, 23 Apr 2010 16:56:35 +0200
From: pacopyc <paco...@gmail.com>
To: python-win32@python.org
Subject: [python-win32] get installed software remote machine
Message-ID: <4bd1b523.1030...@gmail.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Hi, one question for you? Or better .. another question for you?
I'm trying to get installed software on remote host with Win32_Product().
The problem is that don't list all installed software (much but not
all). Why?
What must I use to get all installed software?
Thank you very much
Can you answer my last post "set password administrator host"?
Is not possible do it?
------------------------------
Message: 2
Date: Fri, 23 Apr 2010 16:03:21 +0100
From: Tim Golden <m...@timgolden.me.uk>
Cc: python-win32@python.org
Subject: Re: [python-win32] get installed software remote machine
Message-ID: <4bd1b6b9.8050...@timgolden.me.uk>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
On 23/04/2010 15:56, pacopyc wrote:
Hi, one question for you? Or better .. another question for you?
I'm trying to get installed software on remote host with Win32_Product().
The problem is that don't list all installed software (much but not
all). Why?
What must I use to get all installed software?
Have a look at Mike Driscoll's article:
http://www.blog.pythonlibrary.org/2010/03/03/finding-installed-software-using-python/
Can you answer my last post "set password administrator host"?
Is not possible do it?
Does this take you anywhere?
http://blogs.technet.com/heyscriptingguy/archive/2004/10/15/how-can-i-change-a-user-s-password.aspx
TJG
------------------------------
_______________________________________________
python-win32 mailing list
python-win32@python.org
http://mail.python.org/mailman/listinfo/python-win32
End of python-win32 Digest, Vol 85, Issue 27
********************************************
Ok, thank you very much. Very good with set administrator password (it
works), but I've problem with installed software. The list is not
complete (I don't understand). For example key "Adobe Flash Player
ActiveX" return this error:
Traceback (most recent call last):
File "<pyshell#49>", line 1, in <module>
key = OpenKey(HKEY_LOCAL_MACHINE,
'Software\Microsoft\Windows\CurrentVersion\Uninstall\Adobe Flash Player
ActiveX', 0, KEY_ALL_ACCESS)
WindowsError: [Error 2] Impossibile trovare il file specificato (Impossible
find file)
But key "Software\MicrosoftWindowsCurrentVersion\Uninstall\Adobe Flash
Player ActiveX" exists.
What's the problem? The spaces? I don't think so.
This is the code:
import wmi
from _winreg import (HKEY_LOCAL_MACHINE, KEY_ALL_ACCESS, OpenKey, EnumValue,
QueryValueEx)
host='XXXX'
reg = wmi.WMI(host,namespace="root/default").StdRegProv
result, names = reg.EnumKey
(hDefKey=HKEY_LOCAL_MACHINE,sSubKeyName=r"Software\Microsoft\Windows\CurrentVersion\Uninstall")
keyPath = r"Software\Microsoft\Windows\CurrentVersion\Uninstall"
count = 0
while count <= len(names):
try:
print names[count]
path = keyPath + "\\" + names[count]
key = OpenKey(HKEY_LOCAL_MACHINE, path, 0, KEY_ALL_ACCESS)
temp = QueryValueEx(key, 'DisplayName')
display = str(temp[0])
print names[count]+" -> "+display
count += 1
except:
count += 1
continue
Thanks again
_______________________________________________
python-win32 mailing list
python-win32@python.org
http://mail.python.org/mailman/listinfo/python-win32