You need to make sure that you call CoInitailize for each thread that will create COM objects. Basically this function inidicates to OLE which type of threading model that thread will use when it creates COM objects.
Build a man a fire, and he will be warm for a day
Light a man on fire, and he will be warm for the rest of his life!