CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Dec 2011
    Posts
    4

    [RESOLVED] Mulitple instances of COM object

    I have an application where I have to call COM instances one after another. The problem is -- second COM instance does not get invoked, until the first one finishes. I debugged through and it is hung up on CreateInstance() function.

    I did some other tests and found that if I run two instances of my application and then invoke COM from both the applications, both the COM executes. So I'm not sure if this an application limitation or COM limitation.

    Can anyone please shed some light on this?

  2. #2
    Join Date
    Jul 2005
    Location
    Netherlands
    Posts
    2,042

    Re: Mulitple instances of COM object

    Cheers, D Drmmr

    Please put [code][/code] tags around your code to preserve indentation and make it more readable.

    As long as man ascribes to himself what is merely a posibility, he will not work for the attainment of it. - P. D. Ouspensky

  3. #3
    Join Date
    Dec 2011
    Posts
    4

    Re: Mulitple instances of COM object

    Thanks D_Drmmr. I changed the threading model to "Free" or "Both" and now it is working!

  4. #4
    Join Date
    Jul 2005
    Location
    Netherlands
    Posts
    2,042

    Re: [RESOLVED] Mulitple instances of COM object

    You're welcome.
    Cheers, D Drmmr

    Please put [code][/code] tags around your code to preserve indentation and make it more readable.

    As long as man ascribes to himself what is merely a posibility, he will not work for the attainment of it. - P. D. Ouspensky

Tags for this Thread

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