Solved

Need to Load an EXE file inside a MDI form

Posted on 2008-10-16
2
557 Views
Last Modified: 2013-12-26
Hi all,

I'm building an application that is a wrapper for everthing this company needs to do. I have all of their forms, Webbrowser, utilites etc. loading up as child forms in a parent MDI form. The only other thing this company uses is a program that runs all of their Client info and Sales. They would like me to make that executable load up inside my MDI form so they basically can open my program and never have to leave it. I'm not sure how I can do this.... maybe the setparent API?? Could I set that application as a child of my MDI form? Any other implementation ideas?

If any of you have done this.... the code snippet would be great!
0
Comment
Question by:md0333
2 Comments
 
LVL 25

Accepted Solution

by:
Luis Pérez earned 500 total points
ID: 22738415
I guess SetParent could be what you're looking for. MDI parent windows are specially prepared to contain other windows, so it will manage well. But you'll need to get the hWnd of the main window of the application that you want to embed inside your MDI. One possible approach to this is using FindWindow API, that will return the hWnd of a window based on it's window bar title. If the title of the application'stitle bar is more or less unique, you can then use FindWindow to get it's hWnd and then use SetParent to make it child of your MDI form.
0
 

Expert Comment

by:anil_marar
ID: 23508563
Container for EXE files
Hi, I have three seperate Applications(exe) files belonging to same bussiness. I need to make a container application for these applications. I have tried it by using the setparent API. But since the applictions has MDI forms in it, it is not woriking properly. Can somebody help me in this issue ? Thanks in advance.

Regards
Anil
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

932 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now