BCGSoft Forums
BCGSoft Forums
Home | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 BCGControlBar Pro for MFC Forums
 BCGControlBar Professional Edition
 Icon on disabled button (visual style)

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkInsert EmailInsert Image Insert CodeInsert QuoteInsert List Insert Smilie

* Forum Code is ON


T O P I C    R E V I E W
tomaskrasa Posted - 07/03/2022 : 01:59:23 AM

Inside CBCGPFormView i have several buttons.

Without EnableVisualManagerStyle() icon on disabled button

(only 1 icon set to button - via message BM_SETIMAGE)

With EnableVisualManagerStyle() icon on disabled button

It is ugly.

Is there easy way how to show icon on disabled button same way as without visual style ?

4   L A T E S T    R E P L I E S    (Newest First)
tomaskrasa Posted - 07/04/2022 : 04:02:21 AM
Thank you very much for help.

Great library and excelent support.
Support Posted - 07/04/2022 : 02:18:05 AM

The icon should be 32bpp:

m_wndStartAnimation.SetImage(h_ico, TRUE, NULL, NULL, TRUE);

Best regards,
tomaskrasa Posted - 07/03/2022 : 06:17:06 AM
Thank for fast reply.

I have explored BCGPControls example - Static text and picture page.

It work as expected for PNG bitmap in example.
But it does not work for icon bitmap.

If i change:
StaticControlsView.cpp line 114

from PNG bitmap:
m_wndStartAnimation.SetImage(IDB_PLAY32); // use PNG bitmap

to icon:
HICON h_ico = (HICON)LoadImage(AfxGetApp()->m_hInstance, MAKEINTRESOURCE(IDI_INFO), IMAGE_ICON, 16, 16, LR_SHARED);

it work same way as in my first post (ugly full gray icon if button disabled)
Support Posted - 07/03/2022 : 04:32:01 AM

Thank you for contacting us!

First, we're kindly asking to read our forum rules:

3. If the problem cannot be reproduced in our examples/samples, please open a new support ticket ( and attach your sample where we can see the problem.

As you can see in our BCGPcontrols example, disabled push button (with visual style) created in the form view is displayed properly:

So, please open a new ticket and attach the repro sample.

Best regards,

BCGSoft Forums © Copyright (c) 1998-2022 BCGSoft Co Ltd Go To Top Of Page
Snitz Forums 2000