CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 12 of 12

Threaded View

  1. #1
    Join Date
    Jun 2004
    Posts
    204

    Accessing COM EXE-server from diffent threads

    Hi everyone,

    I am stuck with a problem: my MFC-application loads dynamically a DLL which accesses a COM-Server from 3 diffent threads. When the main thread calls functions from the COM-server it all works fine but if another thread tries to access any function from the COM-server I receive an error.
    CoInitializeEx(NULL, COINIT_MULTITHREADED) is executed in all threads before accessing the server.
    For test purposes I have written a small programm (also MFC) which does the same as my application (calls same function inside the DLL) but here it works fine.

    Has someone any clue what the issue may be?


    Edit: the code is 8001010e: The application called an interface that was marshalled for a different thread.


    Regards
    Padan.
    Last edited by Padan; July 28th, 2009 at 07:03 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured