[Zope] COM-Error: CoInitalize was not called

Andy McKay andy@agmweb.ca
Sun, 26 Jan 2003 20:21:03 -0800


> I am programming a custom COM-Method. However after I call
> win32com.client.Dispatch('NameOf.ComObject') a COM-Error raises
> containing "CoInitalize was not called". I am working with Zope 2.6.0 on

Call CoInitialize or CoInitializeEx first. eg:

from pythoncom import CoInitializeEx, COINIT_MULTITHREADED
CoInitializeEx(COINIT_MULTITHREADED)

Cheers.
-- 
   Andy McKay