HBITMAP GetBitmap( ) const;
Return Value
A handle to a bitmap. NULL if no bitmap is previously specified.
Remarks
Call this member function to get the handle of a bitmap, previously set with SetBitmap, that is associated with a button.
Example
CButton myButton;
// Create a bitmap button.
myButton.Create(_T("My button"), WS_CHILD|WS_VISIBLE|BS_BITMAP,
CRect(10,10,60,50), pParentWnd, 1);
// If no bitmap is defined for the button, define the bitmap to the
// system close bitmap.
if (myButton.GetBitmap() == NULL)
myButton.SetBitmap( ::LoadBitmap(NULL, MAKEINTRESOURCE(OBM_CLOSE)) );
CButton Overview | Class Members | Hierarchy Chart
See Also CButton::SetBitmap, CBitmapButton::LoadBitmaps, Bitmaps