I’m writing an application to control some PLC’s,and
during initialization a little Window pops up with ‘Python Error’
in the title and the message ‘Cannot Initialize OLE’. It
doesn’t seem to affect my application other than that error message at
the start. I’ve got a GUI running in the main thread, 1 thread
doing OPC communications to an OPC server (thanks to some help from Norm
Petterson), and two other worker threads implementing business
logic. The main thread creates a couple Queues and passes them to the
other threads so they can all communicate. In the main thread, I’ve
set sys.coinit_flags = 0 before importing pythoncom. Each of the other
threads call pythoncom.CoInitializeEx(pythoncom.COINIT_MULTITHREADED). I
have Mark Hammond’s book on python programming on Win32, but I’m
still confused on how exactly to get all my threads communicating well. This
setup seems to work, except for that error window that pops up near the start
(I can’t even tell exactly where it’s cropping up). Does anyone know what causes this error window, or what I’m
doing wrong? Thanks for any help, |
_______________________________________________ Python-win32 mailing list Python-win32@python.org http://mail.python.org/mailman/listinfo/python-win32