python: _winreg problem

无人久伴 提交于 2019-12-03 22:42:12

问题


the windows registry may contain keys whose names with embedded nulls

when i call _winreg.OpenKey(key, subkey_string_with_embbeded_null) i get the following error:

TypeError: OpenKey() argument 2 must be string without null bytes or None, not str

Q1: is the meaning of the error that python _winreg module has a limitation that it cannot open keys whose names have embbeded nulls?

Q2: how do i get around this limitation?


回答1:


Q1: right.

Q2: download and install win32all.



来源:https://stackoverflow.com/questions/2384064/python-winreg-problem

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!