j'ai un soucis pour aller lire une registry spécifique :
Arrivez-vous à lancer cette commande ?
Code : Tout sélectionner
registry_readstring(HKEY_LOCAL_MACHINE, 'SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Group Policy\\State\\Machine\\Scripts\\Shutdown\\0\\0','Script')
La commande fonctionne pourtantsur arborescence supérieure par exemple
Code : Tout sélectionner
registry_readstring(HKEY_LOCAL_MACHINE, 'SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Group Policy\\State\\Machine\\Scripts\\Shutdown\\0','DisplayName')
Code : Tout sélectionner
reg_key_exists(HKEY_LOCAL_MACHINE, 'SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Group Policy\\State\\Machine\\Scripts\\Shutdown\\0')
mais
Code : Tout sélectionner
reg_key_exists(HKEY_LOCAL_MACHINE, 'SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Group Policy\\State\\Machine\\Scripts\\Shutdown\\0\\0')
Code : Tout sélectionner
Traceback (most recent call last):
File "<console>", line 1, in <module>
File "C:\Program Files (x86)\wapt\waptutils.py", line 2786, in reg_key_exists
with reg_openkey_noredir(rootkey, subkeypath):
AttributeError: __enter__
Merci !
Bonne journée,