pywintypes.com_error: (-2147221008, ‘尚未调用 CoInitialize。’, None, None)
查阅各种资料,终于找到解决方案,在最后的"D: conda\envs\project\lib\site-packages\win32com \client\init"报错的
dispatch = pythoncom.CoCreateInstanceEx(
clsid, None, clsctx, serverInfo, (pythoncom.IID_IDispatch,))[0]
前加入一句
pythoncom.CoInitialize()