Running windows/web application inside another windows application

S

Shiva Ramani

I have a windows application with multiple forms & another web application.
Now I need a parent EXE or Application which need to act as a container to
these application.
Example :
My existing Web application : http://localhost/MyApp/Default.aspx
My existing Win Application : existingWinApp.exe

New Parent WinApp : NewWinApp.exe

My new winapp will have a menu & below which I will have a form holder.
Based on my menu selection (Winapp or webapp) respective app should load
inside the form holder.

More like running different app domains inside one app domain. Correct me if
iam wrong
 
J

JDeats

I have a windows application with multiple forms & another web application.
Now I need a parent EXE or Application which need to act as a container to
these application.
Example :
My existing Web application : http://localhost/MyApp/Default.aspx
My existing Win Application : existingWinApp.exe

New Parent WinApp : NewWinApp.exe

My new winapp will have a menu & below which I will have a form holder.
Based on my menu selection (Winapp or webapp) respective app should load
inside the form holder.

More like running different app domains inside one app domain. Correct me if
iam wrong


I'm not sure what your question is. Are you asking for architecture/
design advice? Are you asking the basics of how you would implement
this? Could you form coherent problem statement and repost?
 
S

Shiva Ramani

I would like to know how i can call another windows application inside a
windows form.
 
F

Family Tree Mike

I don't believe this is possible. It is possible of course to launch a
separate process from your form, and to add a webbrowser control navigated
to your site within your form.

Have you ever seen any programs which contain a separate executable running
from within that apps main window?
 
J

JDeats

I would like to know how i can call another windows application inside a
windows form.

You can't embed one WinForm inside another. However, you could use
Reflection to create an loosely coupled reference to your other
application and if the Form classes are public then you could load
them and get/set public properties, call methods etc.... You could
also launch the target application using System.Diagnostic Process...

Looking back your top post it sounds as if you want to be able to keep
a top level menu in your container app and allow the end user to use
this menu to manipulate either the Windows or Web based child apps.
You may be able to accomplish the web bit using the web browser
control, but as someone else stated it's not possible to embed a
WinForm in this manner.
 
S

Shiva Ramani

I agree launching web app is possible with webbrowser control. Few
applications inside our organization are using this kind of architecture in
VB forms. Parent VB forms hold multiple different systems inside its child
form.
I want to know if this is possible with .NET. if iam making use of
reflection is it possible to control the child app inside the parent
(container) app's domain.
 
F

Family Tree Mike

As JDeats correctly stated, you could use reflection to add and control the
main form of the other application within your application. That is
different from adding the application to your form.

The biggest difference I could see is that if your container launched a
modal dialog, this child form would be inaccessable, wherein as a separate
executable, it would be independant and accessable. Also, if your child
form lauched a modal dialog, your container app would be inaccessable.

Since you said others in your organization are doing what you desire, then
you should ask the manner that they achieved it. I'm sure the community
here would like to understand how it is done.
 
S

Shiva Ramani

Can you pls explain me how adding & controlling the main form of other
application within my app is different from application to my form ?
 

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