如何使用python打开设备管理器?我使用子流程库:
import subprocess
subprocess.call("devmgmt.msc")
我收到此错误:
File "c:\Wichtig\python\admpwd\admpwd.py", line 3, in <module>
subprocess.call("devmgmt.msc")
File "C:\Python37\lib\subprocess.py", line 304, in call
with Popen(*popenargs, **kwargs) as p:
File "C:\Python37\lib\subprocess.py", line 756, in __init__
restore_signals, start_new_session)
File "C:\Python37\lib\subprocess.py", line 1155, in _execute_child
startupinfo)
OSError: [WinError 193] %1 is not a valid Win32 application