Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Command Bars
  New Posts New Posts RSS Feed - Add Menu in Applicaton Based on Dialog
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Add Menu in Applicaton Based on Dialog

 Post Reply Post Reply
Poll Question: Add Menu in Applicaton Based on Dialog
Poll Choice Votes Poll Statistics
0 [0.00%]
0 [0.00%]
You can not vote in this poll

Author
Message
suntimes View Drop Down
Newbie
Newbie


Joined: 08 May 2007
Status: Offline
Points: 1
Post Options Post Options   Thanks (0) Thanks(0)   Quote suntimes Quote  Post ReplyReply Direct Link To This Post Topic: Add Menu in Applicaton Based on Dialog
    Posted: 08 May 2007 at 9:19am

I use Xtreme ToolkitPro v10.3.1 to beautify the application based on dialog. After I loaded a skin, the menu disappeared. Then I write the code as follow:

    // Initialize the command bars
 if (!m_wndStatusBar.Create(this) ||
        !m_wndStatusBar.SetIndicators(indicators,
        sizeof(indicators)/sizeof(UINT)))
    {
        TRACE0("Failed to create status bar\n");
        return -1;      // fail to create
    }

 if (!InitCommandBars())
        return -1;

 CXTPCommandBars* pCommandBars = GetCommandBars();
 // Add the menu bar
 CXTPCommandBar* pMenuBar = pCommandBars->SetMenu(
  _T("Menu Bar"), IDR_MAINFRAME);
 if(pMenuBar == NULL)
 {
  TRACE0("Failed to create menu bar.\n");
  return -1;      // fail to create
 }

And I change the dialog derive from CDialogSampleDlgBase. But  I still can't get the menu in the dialog. What should I do more?
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.156 seconds.