Solved

Creating A DialogBar.

Posted on 1997-10-18
2
382 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
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

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

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

Suggested Solutions

Introduction: Dynamic window placements and drawing on a form, simple usage of windows registry as a storage place for information. Continuing from the first article about sudoku.  There we have designed the application and put a lot of user int…
Introduction: Displaying information on the statusbar.   Continuing from the third article about sudoku.   Open the project in visual studio. Status bar – let’s display the timestamp there.  We need to get the timestamp from the document s…
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.
Along with being a a promotional video for my three-day Annielytics Dashboard Seminor, this Micro Tutorial is an intro to Google Analytics API data.

810 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