CStatic::GetBitmap

HBITMAP GetBitmap( ) const;

Return Value

A handle to the current bitmap, or NULL if no bitmap has been set.

Remarks

Call this member function to get the handle of the bitmap, previously set with SetBitmap, that is associated with CStatic.

Example

CStatic myStatic;

// Create a child bitmap static control.
myStatic.Create(_T("my static"), 
   WS_CHILD|WS_VISIBLE|SS_BITMAP|SS_CENTERIMAGE, CRect(10,10,150,50), 
   pParentWnd);

// If no bitmap is defined for the static control, define the bitmap 
// to the system close bitmap.
if (myStatic.GetBitmap() == NULL)
   myStatic.SetBitmap( ::LoadBitmap(NULL, MAKEINTRESOURCE(OBM_CLOSE)) );

CStatic OverviewClass MembersHierarchy Chart

See Also   CStatic::SetBitmap, STM_GETIMAGE, Bitmaps