Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Launch & controlling a new application instance via COM

Status
Not open for further replies.

dotNetNob09

Programmer
Feb 4, 2009
2
US
I am having a problem where I have a COM application that can be run stand-alone and programatically via COM interop. If an instance of the COM application is being run when my .NET application that does the COM interop starts, it latches onto a currently running instance rather than making a new instance for itself.


So here are the facts of my situation.



I have a Delphi 7 app that implements a COM Server.


I have imported a reference to this application in a VS 2008 project by adding a reference to the COM server.


It works great if there are no previous running instances of the application prior to executing my .NET application.


If there is 1 or more instances of the application executing, when the constructor for implementing the COM Interop class is executed it just latches on or hooks into one of the already running instance of the application.


Instead of the above happening I would like to create a new instance of the application and hook onto that one.


I think that the above points make my very special situation really clear.

Any help would be appreciated.

I am new to COM Interop, but wouldn't this be the same as doing automation in Word or Excel? This issue would most likely come up a lot I would think.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top