[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

COM server  hangs  when the user presses  "stop debugging" from Visual Studio menus

Posted on 2001-07-20
3
Medium Priority
?
229 Views
Last Modified: 2013-11-20
Hi,

I have a COM object( let us say "first") which creates an instance of another COM object called Test. My application is integrated with VC++ and we allow this "Test" object to be debugged from our application through Visual Studio. When an user is debugging the "TEST" component from our application, the user suddenly presses "stop debugging" in the VC++ menus.
Now, The COM server/exe( "TEST" object) dies since the user has pressed "stop debugging". Here, the COM object "TEST" created using "first" Object is being debugging by VC++ from my application.

The problem is that, when the user presses "stop debugging" from VC++ for the "test" COM object, the "first" COM object hangs sometimes...because
"first" COM object holds a reference to this "TEST" object which is dead (because the user presses "stop debugging" from VC++ menus for the "TEST" object). Sometimes, the "first" com object returns a RPC Error like a good boy.Sometimes it hangs.

Is there anyway to prevent this hang ?

Thanks for your time & help,

Sankar









0
Comment
Question by:sankar012898
  • 2
3 Comments
 
LVL 9

Expert Comment

by:ShaunWilde
ID: 6305124
have disconnect option on your first object which you can call - which will disconnect it from the TEST object and then 'stop debugging' the TEST object
0
 

Author Comment

by:sankar012898
ID: 6310845
Hi Shaun Wilde,

Thanks for your answer. It was very useful to us.
Please put it as an "answer" and I will accept it.

Thanks
Sankar
0
 
LVL 9

Accepted Solution

by:
ShaunWilde earned 600 total points
ID: 6311331
an answer see above - by the way you can also accept comments as answers
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Ownerdraw of the grid button.  A singleton class implentation and usage. Continuing from the fifth article about sudoku.   Open the project in visual studio. Go to the class view – CGridButton should be visible as a class.  R…
Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…
Suggested Courses

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question