Using A Small Icon With The Tab Label

Environment: VC6 SP5

Usage

The code to add small icon to the tab label should be placed in the constructor of CMyPropertySheet.

CMyPropertySheet is derived from CPropertySheet.
The object m_Page1 is defined in the header file:
CMyPage m_Page1;

CMyPage is derived from CPropertyPage.
IDI_SMALL_ICON is ID number of the icon resource(small).
CMyPropertySheet::CMyPropertySheet(CWnd* pWndParent)
: CPropertySheet(IDS_PROPSHT_CAPTION, pWndParent)
{
  m_Page1.m_psp.dwFlags |= PSP_USEHICON ;
  m_Page1.m_psp.hIcon = AfxGetApp() -> LoadIcon(IDI_SMALL_ICON);

  AddPage(&m_Page1);
}


Comments

  • yesyes...but in 32bits color?

    Posted by Legacy on 10/03/2003 12:00am

    Originally posted by: vv

    mmm...any idea is welcome

    Reply
Leave a Comment
  • Your email address will not be published. All fields are required.

Top White Papers and Webcasts

  • Live Event Date: September 16, 2014 @ 11:00 a.m. ET / 8:00 a.m. PT Are you starting an on-premise-to-cloud data migration project? Have you thought about how much space you might need for your online platform or how to handle data that might be related to users who no longer exist? If these questions or any other concerns have been plaguing you about your migration project, check out this eSeminar. Join our speakers Betsy Bilhorn, VP, Product Management at Scribe, Mike Virnig, PowerSucess Manager and Michele …

  • Live Event Date: September 17, 2014 @ 1:00 p.m. ET / 10:00 a.m. PT Another day, another end-of-support deadline. You've heard enough about the hazards of not migrating to Windows Server 2008 or 2012. What you may not know is that there's plenty in it for you and your business, like increased automation and performance, time-saving technical features, and a lower total cost of ownership. Check out this upcoming eSeminar and join Rich Holmes, Pomeroy's practice director of virtualization, as he discusses the …

Most Popular Programming Stories

More for Developers

Latest Developer Headlines

RSS Feeds