Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6925811
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T10:50:16+00:00 2026-05-27T10:50:16+00:00

In Visual C++, I have a CMFCOutlookBarTabCtrl that has been created with: CMFCOutlookBarTabCtrl* pOutlookBar

  • 0

In Visual C++, I have a CMFCOutlookBarTabCtrl that has been created with:

CMFCOutlookBarTabCtrl* pOutlookBar = (CMFCOutlookBarTabCtrl*) m_wndContextBar.GetUnderlyingWindow();

where wndContextBar is a CMyOutlookBar that is a class I derived from CMFCOutlookBar

I also have the 3 CMFCOutlookBarPanes I create within the if below:

DWORD dwPaneStyle = AFX_DEFAULT_TOOLBAR_STYLE | CBRS_FLOAT_MULTI;

// can float, can autohide, can resize, CAN NOT CLOSE
DWORD dwStyle = AFX_CBRS_FLOAT | AFX_CBRS_AUTOHIDE | AFX_CBRS_RESIZE | CBRS_GRIPPER;

if (!m_wndPane0.Create(&m_wndContextBar, dwPaneStyle, PANE0_ID, dwStyle) ||
    !m_wndPane1.Create(&m_wndContextBar, dwPaneStyle, PANE1_ID, dwStyle) ||
    !m_wndPane2.Create(&m_wndContextBar, dwPaneStyle, PANE2_ID, dwStyle))
    )
{
    ASSERT(FALSE);
    return FALSE;
}

And the code follows:

m_wndPane0.SetOwner(this);
m_wndPane1.SetOwner(this);
m_wndPane2.SetOwner(this);
m_wndPane0.EnableTextLabels();
m_wndPane1.EnableTextLabels();
m_wndPane2.EnableTextLabels();

m_wndPane0.EnableDocking(CBRS_ALIGN_ANY);
m_wndPane1.EnableDocking(CBRS_ALIGN_ANY);
m_wndPane2.EnableDocking(CBRS_ALIGN_ANY);

    [....]//Code for adding buttons inside the panes, it is irrelevant for this discussion

pOutlookBar->SetImageList(IDB_CONTEXT_ICONS, 32, RGB(255,255,255));

sTitle.LoadString(IDS_PANE0);
pOutlookBar->AddControl(&m_wndPane0, sTitle, 0, TRUE, dwStyle); 
m_wndPane0.EnableDocking(CBRS_ALIGN_ANY);
m_wndPane0.SetDefaultState();

sTitle.LoadString(IDS_PANE1);
pOutlookBar->AddControl(&m_wndPane1, sTitle, 1, TRUE, dwStyle); 
m_wndPane1.EnableDocking(CBRS_ALIGN_ANY);
m_wndPane1.SetDefaultState();

sTitle.LoadString(IDS_PANE2);
pOutlookBar->AddControl(&m_wndPane2, sTitle, 2, TRUE, dwStyle); 
m_wndPane2.EnableDocking(CBRS_ALIGN_ANY);
m_wndPane2.SetDefaultState();

m_wndContextBar.SetPaneStyle(m_wndContextBar.GetPaneStyle() | CBRS_TOOLTIPS | CBRS_FLYBY | CBRS_SIZE_DYNAMIC);
m_wndContextBar.FillDefaultTabsOrderArray();

pOutlookBar->EnableTabSwap(TRUE);

CMFCOutlookBarTabCtrl::EnableAnimation(TRUE);

UpdateMDITabbedBarsIcons();

I define that icons will be appearing on the panes with the SetImageList line above. When I create the Toolbar everything is OK. But when I try to drag one of the Panes to another position inside the Outlook bar, its icon disappears.

So, what is the solution for the image to be visible after dragging?

Side note: When dragging, the Pane passes temporarily to a state where it is undocked, where its title bar is shorter and has no icon, which does not seem incorrect to me. What is really irritating is when the Pane is redocked the returns to its original height as expexted, but the icon isn’t shown.

Thanks in advance for help,
Sérgio

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T10:50:16+00:00Added an answer on May 27, 2026 at 10:50 am

    Not really a solution again, but I’ve managed to have the panels “position-locked” without having the mode 2003:

    CString sTitle;
    sTitle.LoadString(IDS_CONTEXT);
    
    //m_wndContextBar.SetMode2003();
    if (!m_wndContextBar.Create(sTitle, this, CRect(0, 0, 150, 400), CONTEXT_TAB_ID, 
                                WS_CHILD|WS_VISIBLE|CBRS_LEFT/*|CBRS_GRIPPER*/, 
                                AFX_CBRS_RESIZE|AFX_CBRS_CLOSE|AFX_CBRS_AUTOHIDE/*|AFX_CBRS_FLOAT*/))
    {
        ASSERT(FALSE);
        return FALSE;
    }
    
    CMFCOutlookBarTabCtrl* pOutlookBar = (CMFCOutlookBarTabCtrl*) m_wndContextBar.GetUnderlyingWindow();
    if (!pOutlookBar)
    {
        ASSERT(FALSE);
        return FALSE;
    }
    
    DWORD dwPaneStyle = AFX_DEFAULT_TOOLBAR_STYLE;
    DWORD dwStyle = NULL;
    
    if (!m_wndPane0.Create(&m_wndContextBar, dwPaneStyle, PANE0_ID, dwStyle) ||
        !m_wndPane1.Create(&m_wndContextBar, dwPaneStyle, PANE1_ID, dwStyle) ||
        !m_wndPane2.Create(&m_wndContextBar, dwPaneStyle, PANE2_ID, dwStyle))
    {
        ASSERT(FALSE);
        return FALSE;
    }
    
    m_wndPane0.SetOwner(this);
    m_wndPane1.SetOwner(this);
    m_wndPane2.SetOwner(this);
    m_wndPane0.EnableTextLabels();
    m_wndPane1.EnableTextLabels();
    m_wndPane2.EnableTextLabels();
    
    m_wndPane0.EnableDocking(CBRS_ALIGN_TOP);
    m_wndPane1.EnableDocking(CBRS_ALIGN_TOP);
    m_wndPane2.EnableDocking(CBRS_ALIGN_TOP);
    

    [….]//Code for adding buttons inside the panes, it is irrelevant for this discussion

    pOutlookBar->SetImageList(IDB_CONTEXT_ICONS, 32, RGB(255,255,255));
    
    sTitle.LoadString(IDS_PANE0);
    pOutlookBar->AddControl(&m_wndPane0, sTitle, 0, TRUE, dwStyle); 
    m_wndPane0.SetDefaultState();
    
    sTitle.LoadString(IDS_PANE1);
    pOutlookBar->AddControl(&m_wndPane1, sTitle, 1, TRUE, dwStyle); 
    m_wndPane1.SetDefaultState();
    
    sTitle.LoadString(IDS_PANE2);
    pOutlookBar->AddControl(&m_wndPane2, sTitle, 2, TRUE, dwStyle); 
    m_wndPane2.SetDefaultState();
    
    
    m_wndContextBar.SetPaneStyle(m_wndContextBar.GetPaneStyle() | CBRS_TOOLTIPS | CBRS_FLYBY | CBRS_SIZE_DYNAMIC);
    m_wndContextBar.FillDefaultTabsOrderArray();
    
    pOutlookBar->EnableTabSwap(FALSE);
    pOutlookBar->EnableTabDetach(0,FALSE);
    pOutlookBar->EnableTabDetach(1,FALSE);
    pOutlookBar->EnableTabDetach(2,FALSE);
    //pOutlookBar->EnableTabDetach(3,FALSE);
    
    CMFCOutlookBarTabCtrl::EnableAnimation(TRUE);
    
    UpdateMDITabbedBarsIcons();
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have visual Studio 2008. I have noticed that I cam make WPF applications
I have Visual 2010, I am trying to generate dal from my database. I
I have Visual Studio 2008 running from Windows XP. Our server is Windows 2003
I have Visual Studios 2010 Pro I read that apparently the older versions of
I have Visual studio 2010 that work with TFS 2008. How Do I Use
I tried to have Visual Studio 2010 create unit tests for the following class,
Is it possible to have Visual Studio's Class View pane (available under View >
1. Assuming that you don't have Visual Studio installed and you want to use
I have Visual Studio projects that I would like to compile on Linux and
Does Visual Studio have a user guide, or any such document that provides the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.