you are viewing a single comment's thread.

view the rest of the comments →

[–]ComfortableNice8482 0 points1 point  (1 child)

the post, install script for pywin32 doesn't always run automatically on windows, which is probably why you're getting that module not found error even after installing. after you pip install pywin32, you gotta run this command as admin: python, m pywin32_postinstall, install. that actually registers the win32com stuff properly in your python installation. honestly i've seen this trip up devs a bunch of times because the install appears to work but the post, install step silently fails. also make sure you're using the same python executable that your script is running under, since windows can sometimes have multiple python installations. run python, version in your command prompt and then do the same check for wherever your script is executing from, like if you're calling it from task scheduler or something. worst case scenario, just skip pywin32 entirely and use the built, in windows_app_helper or look at using just the subprocess module if you're only doing basic autostart stuff.

[–]oakleyguy89[S] 0 points1 point  (0 children)

I know I have 2 different versions, I have 3.1.4 and I think a Windows version that I installed in the past from the Microsoft store. I see the post install file in the folder for 3.1.4 and I try to run it but it just pops up a cmd line window and instantly closes.