Print Page | Close Window

Menu Prompts Not Displayed in Ribbon Status Bar

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Command Bars
Forum Description: Topics Related to Codejock Command Bars
URL: http://forum.codejock.com/forum_posts.asp?TID=9572
Printed Date: 01 March 2025 at 9:57am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Menu Prompts Not Displayed in Ribbon Status Bar
Posted By: cjsnewbie
Subject: Menu Prompts Not Displayed in Ribbon Status Bar
Date Posted: 12 February 2008 at 6:21pm
Hi,
 
I'm creating my ribbon bar like this...
 

this is defined in header file as - CXTPStatusBar m_wndStatusBar

int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)

{

XTPSkinManager()->Remove(m_hWnd);

if (CXTPFrameWnd::OnCreate(lpCreateStruct) == -1)

    return -1;

if (!m_wndStatusBar.Create(this))

{

TRACE0("Failed to create status bar\n");

       return -1;

}

if (!InitCommandBars())

       return -1;

CXTPCommandBars* pCommandBars = GetCommandBars();

m_wndStatusBar.SetCommandBars(pCommandBars);

pCommandBars->SetTheme(xtpThemeRibbon);

pCommandBars->GetImageManager()->SetIcons(IDR_SMALLICONS);

m_wndStatusBar.SetFont(pCommandBars->GetPaintManager()->GetIconFont());

 
CXTPToolTipContext* pToolTipContext = GetCommandBars()->GetToolTipContext();

pToolTipContext->SetStyle(xtpToolTipOffice2007);

pToolTipContext->ShowTitleAndDescription();

pToolTipContext->ShowImage(TRUE, 0);

pToolTipContext->SetMargin(CRect(2, 2, 2, 2));

pToolTipContext->SetMaxTipWidth(180);

pToolTipContext->SetFont(pCommandBars->GetPaintManager()->GetIconFont());

if (!CreateRibbonBar())

{

TRACE0("Failed to create ribbon\n");

      return -1;

}

return 0;

}

 
My main problem is that I have menu prompt stings added in resource which should be displayed in status bar. I tried Ribbon bar sample. It is working fine.
 
Can anybody tell me what is wrong in this code? Am I missing anything?
 



Replies:
Posted By: Oleg
Date Posted: 13 February 2008 at 1:14am
Hi,
You need add indicator with Id = 0. See in sample line after m_wndStatusBar.Create


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: cjsnewbie
Date Posted: 13 February 2008 at 2:00pm
Originally posted by oleg oleg wrote:

Hi,
You need add indicator with Id = 0. See in sample line after m_wndStatusBar.Create

Thanks, oleg. That worked. Didn't know at least one indicator is required.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net