Print Page | Close Window

how add a bitmap to status bar

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=2273
Printed Date: 08 November 2025 at 9:49pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: how add a bitmap to status bar
Posted By: stephen_hyc
Subject: how add a bitmap to status bar
Date Posted: 24 May 2005 at 1:14am
how can i add a bitmap to the status bar.



Replies:
Posted By: bevpet
Date Posted: 24 May 2005 at 10:33am

take a look at this sample, it doesn't have bitmaps, but you can easily alter to display a bitmap

http://www.codeproject.com/statusbar/ExtStatusControlBar.asp - http://www.codeproject.com/statusbar/ExtStatusControlBar.asp

 



Posted By: thodgson
Date Posted: 26 May 2005 at 11:41am

// .h
CXTPStatusBar m_wndStatusBar
CXTPStatusBarIconPane m_wndIconPane

// Mainfrm.cpp
static UINT indicators[] =
{
 ID_INDICATOR_ICON  // Service indicator
};

(In OnCreate method)

 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
 }

 // -----> Icon Pane
 if (!m_wndIconPane.Create(NULL, &m_wndStatusBar))
 {
  TRACE0("Failed to create icon pane.\n");
  return -1;
 }
 
 // Initialize the pane info and add the control.
 int nIndex = m_wndStatusBar.CommandToIndex(ID_INDICATOR_ICON);
 ASSERT (nIndex != -1);

 m_wndStatusBar.SetPaneWidth(nIndex, xtAfxData.cxSmIcon);
 m_wndStatusBar.AddControl(&m_wndIconPane, ID_INDICATOR_ICON, FALSE);



-------------
Tim H( http://www.ExclamationSoft.com - http://www.ExclamationSoft.com )
Product: Xtreme Toolkit v13.1
Platform: Vista(x64)-SP1
Language: Visual C++ 6.0
Currently: Satisfied w/ Toolkit



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