Search code examples
c++visual-studio-2008comout-of-process

How to determine the supported thread model of an out-of-process COM server?


Question:

  • How to find the threading models supported by a predefined out-of-process (EXE-based) Server:

  • Using oleview?

  • Or any other valid methods?

Note:

  • Attempting to connect to the above described server to receive event notifications

Solution

  • I'm afraid the question is wrong.

    Threading models (STA, MTA, etc) are a necessary evil that apply only to in-process COM objects, where objects and clients need to coexist in the same process and somehow they must prevent stepping on each other's toes (a fun and lengthy topic).

    Out-of-process (EXE) COM servers live in their own process and manage their own threading as they see fit. COM doesn't know -- and doesn't care.

    So there isn't any "threading model" (in a COM sense) associated with an EXE.

    It sounds like you have a specific problem: If you post more details, I/someone/we might be able to help.