Discussion:
ComCtl32.dll Version 6.0 - different using VS 2005?
(too old to reply)
unknown
2007-01-19 13:23:55 UTC
Permalink
Hello experts!

In my application (fully written in C++) I use the BCM_SETIMAGELIST message
to display different icons on a button if the UI is in themed mode.
I just converted the application from C++ 7.1 (VS 2003) to C++ 8.0 (VS 2005)
without modification on the code displaying the icons on the button.
But now, the message BCM_SETIMAGELIST always returns FALSE, and no icon gets
displayed on the button.

Has anyone an idea what this might be caused from?

My code:
// set symbol
BUTTON_IMAGELIST __bil;
__bil.himl = imagelistHandle;
__bil.margin.left = 2;
__bil.margin.top = 2;
__bil.margin.right = 2;
__bil.margin.bottom = 2;
__bil.uAlign = BUTTON_IMAGELIST_ALIGN_CENTER;
if (!::SendDlgItemMessage(hwndDlg, DLG_ITEM_ID, BCM_SETIMAGELIST, (WPARAM)0,
(LPARAM)&__bil))
{
// execution always reaches this point
}


Thanks in advance!
Max
unknown
2007-01-19 13:35:20 UTC
Permalink
Ok, i solved it.
In VS 2003 I manually added a resource-type called RT_MANIFEST which
contained a binary resource with id 1 that holds the manifest-xml-data.
Now in VS 2005 I deleted that resource, opened "Project Settings" ->
"Manifest Tool" and added the file which holds my manifest under "Additional
Manifests".

That works!
Max
Post by unknown
Hello experts!
In my application (fully written in C++) I use the BCM_SETIMAGELIST
message to display different icons on a button if the UI is in themed
mode.
I just converted the application from C++ 7.1 (VS 2003) to C++ 8.0 (VS
2005) without modification on the code displaying the icons on the button.
But now, the message BCM_SETIMAGELIST always returns FALSE, and no icon
gets displayed on the button.
Has anyone an idea what this might be caused from?
// set symbol
BUTTON_IMAGELIST __bil;
__bil.himl = imagelistHandle;
__bil.margin.left = 2;
__bil.margin.top = 2;
__bil.margin.right = 2;
__bil.margin.bottom = 2;
__bil.uAlign = BUTTON_IMAGELIST_ALIGN_CENTER;
if (!::SendDlgItemMessage(hwndDlg, DLG_ITEM_ID, BCM_SETIMAGELIST,
(WPARAM)0, (LPARAM)&__bil))
{
// execution always reaches this point
}
Thanks in advance!
Max
Loading...