Print Page | Close Window

Adding Bitmap to Submenu

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=1023
Printed Date: 11 May 2024 at 10:39pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Adding Bitmap to Submenu
Posted By: Alex H.
Subject: Adding Bitmap to Submenu
Date Posted: 05 August 2004 at 10:12am

How can I set the Bitmap of a submenu with Toolkit Pro 8.7 ?




Replies:
Posted By: Oleg
Date Posted: 10 August 2004 at 3:18am

int CMainFrame::OnCreateControl(LPCREATECONTROLSTRUCT lpCreateControl)
{
 if (lpCreateControl->bToolBar == FALSE)
 {
  if (lpCreateControl->controlType == xtpControlPopup && lpCreateControl->strCaption == _T("&Favoriten"))
  {
   CXTPControlPopup* pControl = CXTPControlPopup::CreateControlPopup(xtpControlPopup);     
   pControl->SetStyle(xtpButtonIconAndCapt ion);
   lpCreateControl->nID = ID_EXTRAS_FAFORITE;
   
   
   CXTPPopupBar* pPopupBar = CXTPPopupBar::CreatePopupBar(GetCommandBars());
   pPopupBar->LoadMenu(lpCreateControl-> ;pMenu->GetSubMenu(lpCreateControl->nIndex), FALSE);

   pControl->SetCommandBar(pPopupBar);
   pPopupBar->InternalRelease();

   lpCreateControl->pControl = pControl;    
   return TRUE;
  }



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



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