We help IT Professionals succeed at work.
Get Started

MFC base dialog class with controls (embedded Visual C++ 4.0)

Last Modified: 2013-12-05
I would like to create a base dialog class (derived from CDialog) and I would like to have it contain some controls like a few text boxes or static controls to hold a time and date string for example, another is a picture control showing the status of the battery). I would like to then use this base class throughout my project for all my dialogs. I am not sure how to do this. I have used the resource editor to create all my dialogs.

Maybe I don't need a base class. What I ultimately want is to not have to cut n paste the same code in every dialog to handle some controls at the top of every window.

What would be very helpful, would be an example project/solution. I don't mind if it is for VS6, VS2003, VS2005 or VS2008.

Thanks in advance.
Watch Question
This problem has been solved!
Unlock 3 Answers and 10 Comments.
See Answers
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE