By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,413 Members | 996 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,413 IT Pros & Developers. It's quick & easy.

how do I get a Resource ID of a CBitmap?

P: n/a
I want to use CBitmapButton. This class knows the function LoadBitmaps
to set a bitmap in a button.

The problem is that LoadBitmaps is asking for a Resource ID.
I have loaded the bmp file in CBitmap, but how do I get this Resource
ID now???

please help

//loading the file 'test.bmp' in CBitmap:
CBitmap bmp;
BITMAP bitmap;
BITMAP bits;

m_pHBitmap = SHLoadDIBitmap("\test\test.bmp");
bmp.Attach(m_pHBitmap);
bmp.GetBitmap(&bitmap);

//now load the bitmap, but this doesn't work!
CBitmapButton::LoadBitmaps(bmp.GetBitmap(&bitmap), 0, 0, 0 );
Jul 22 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
On 4 Dec 2003 02:58:17 -0800, ma**@pcamobile.com (mark) wrote in
comp.lang.c++:
I want to use CBitmapButton. This class knows the function LoadBitmaps
to set a bitmap in a button.


Then you need to ask in a Windows group like
news:comp.os.ms-windows.win32.programmer. These things are not part
of the C++ language, the topic here.

--
Jack Klein
Home: http://JK-Technology.Com
FAQs for
comp.lang.c http://www.eskimo.com/~scs/C-faq/top.html
comp.lang.c++ http://www.parashift.com/c++-faq-lite/
alt.comp.lang.learn.c-c++ ftp://snurse-l.org/pub/acllc-c++/faq
Jul 22 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.