Solved

Converting from SDI to MDI

Posted on 1998-03-06
1
768 Views
Last Modified: 2013-11-20
Does there exist a simple way (tool) to convert an SDI based program into a MDI based program.
0
Comment
Question by:dataman
1 Comment
 
LVL 11

Accepted Solution

by:
mikeblas earned 50 total points
ID: 1316809
Microsoft provides no such tool.

You can convert from SDI to MDI by:

1) Adding your own CMDIChildWnd-derived class. (You can copy the one from a blank AppWizard app.)

2) Changing your CMainFrame class to derive from CMDIFrameWnd instead of CFrameWnd.

3) Changing your InitInstance() code to register a doc template based on your CMDIChildWnd-derived object instead of your plain object.

4) Hook up code to load the main frame:

CMainFrame* pMainFrame = new CMainFrame;
if (!pMainFrame->LoadFrame(IDR_MAINFRAME))
   return FALSE;
m_pMainWnd = pMainFrame;

5) Add a new menu resource for the frame

6) add the appropriate menu items to the document template window style.

.B ekiM
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Here is how to use MFC's automatic Radio Button handling in your dialog boxes and forms.  Beginner programmers usually start with a OnClick handler for each radio button and that's just not the right way to go.  MFC has a very cool system for handli…
This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes.  I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.   Introductio…
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.
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

815 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

8 Experts available now in Live!

Get 1:1 Help Now