Solved

Creating A DialogBar.

Posted on 1997-10-18
2
385 Views
Last Modified: 2013-11-20
Whats the best way to create a dialog bar and attach it to code.  I can create a DialogBar in the resource editor by using the Insert...|DialogBar option.

But when I use ClassWizard to create a new module, I cna't select DialogBar as the base class.

How should I go about it?
0
Comment
Question by:gav061697
[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 Comments
 
LVL 1

Accepted Solution

by:
ohell earned 50 total points
ID: 1308407
If wizard doesn't know about the dialog bar, you just do it manually, I guess. If you want to override the behavior, override a class from CDialogBar, and if not, just call CDialogBar's Create fxn in your parnt frame's OnCreate(), passing the ID of the dialog bar resource to the create fxn...

      if (!m_dialogBar.Create(this, IDD_MyDialogBar, CBRS_TOP | CBRS_TOOLTIPS | CBRS_FLYBY |CBRS_HIDE_INPLACE, ID_TOOLS_DIALOGBAR ))
      {
            TRACE0("Failed to create dialog bar m_dialogBar \n");
            return -1;            // fail to create
      }

And you handle the messages in the frame.

0
 

Expert Comment

by:jorkin
ID: 10727121
I am creating a DialogBar manually, in the way you have described, but I still have one problem:

In the resource editor, I added an edit box to the DialogBar.

Now, I want to associate a CEdit control with the edit box.  Normally, I would go to the wizard and add a variable.  But since the wizard doesn't know about the DialogBar class, I can't do that.

What is the manual alternative?

Thanks.
0

Featured Post

Database Solutions Engineer FAQs

In this series, we will discuss common questions received as a database Solutions Engineer at Percona. In this role, we speak with a wide array of MySQL and MongoDB users responsible for both extremely large and complex environments to smaller single-server environments.

Question has a verified solution.

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

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ā€¦
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
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.
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.

632 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