Export (0) Print
Expand All
Expand Minimize

CListCtrl::GetBkImage

Retrieves the current background image of a list view control.

BOOL GetBkImage(
   LVBKIMAGE* plvbkImage 
) const;

Parameters

plvbkImage
A pointer to an LVBKIMAGE structure containing the current background image of the list view.

Return Value

Returns nonzero if successful, or zero otherwise.

Remarks

This member function implements the behavior of the Win32 macro, ListView_GetBkImage, as described in the Platform SDK.

Example

// The pointer to my list view control.
extern CListCtrl* pmyListCtrl;
LVBKIMAGE bki;

// If no background image is set for the list view control use
// the Microsoft homepage image as the background image.
if (pmyListCtrl->GetBkImage(&bki) && (bki.ulFlags == LVBKIF_SOURCE_NONE))
{
   pmyListCtrl->SetBkImage(
   TEXT("http://www.microsoft.com/library/images/gifs/homepage/microsoft.gif"),
      TRUE);
}

See Also

CListCtrl Overview | Class Members | Hierarchy Chart | CListCtrl::SetBkImage

Show:
© 2014 Microsoft