?
Solved

Connecting Dialog Boxes for outside Files

Posted on 1998-08-07
3
Medium Priority
?
162 Views
Last Modified: 2013-11-20
I have created several dialog boxes in their own files not in the same one and I want to connect them together.  One dialog box is a menu and I want to connect that box to another box which is a screen I made. How do I do this?
Thanks!
0
Comment
Question by:troy24
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 1

Expert Comment

by:slinky
ID: 1320401
I'm not sure what you are trying to do.
more details?
0
 
LVL 1

Accepted Solution

by:
joakimf earned 0 total points
ID: 1320402
Alright, lets say you want to connect them in MyFile.cpp this is what you do:

In MyFile.h add the following:

CMyDialog m_MyDialog;  //Where MyDialog is the name of your Dialog class

Then in MyFile.cpp add the following:

m_MyDialog.DoModal();

This opens MyDialog and then you have to handle the events in the CMyDialog.cpp file.

You can practicly open how many of this Dialog as you like by doing it this way.
Just replace CMyDialog with your Dialogs name.

Good luck....
0
 
LVL 1

Expert Comment

by:joakimf
ID: 1320403
I´m sorry I forgot one important thing. You must include MyDialog.h in MyFile.h otherwise you will get error because CMyDialog will be unidentified......

Just type

#include "MyDialog.h"

above your CMyFile class....
0

Featured Post

Get MySQL database support online, now!

At Percona’s web store you can order your MySQL database support needs in minutes. No hassles, no fuss, just pick and click. Pay online with a credit card.

Question has a verified solution.

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

In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
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.
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Suggested Courses

770 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