Opening another application from .Net application

K

Krish

I have an application that I want to open from my .net application. I
want this application as a clild window of my application. not as a
separate process. Is this posssible?

System.Diagnostics.Process p = new System.Diagnostics.Process();
p.StartInfo.FileName = "Mspaint.exe";
p.Start();

The following code will open mspaint from my application.. but it will
be a free window. I want this to be like a child window of my
application.
 
S

Stuart Nathan

You can try this. It doesn't make it a "child" (I'm not sure actually what
you mean by this) but it does give you control.

Try
MyApp = GetObject(, ""Mspaint.exe") ' in case it's there
Catch ex as Exception
MyApp = CreateObject ( and here you need to do some research )
End Try

you will need to create a reference if you want Intellisense etc. but later
you can use late binding and convert MyApp to Object
 
K

Krish

Stuart Nathan
Will you be able to give me the C# equivalent for this?
What object is MyApp?

Thanks in advance
Kris
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top