BOOL SetBkImage( LVBKIMAGE* plvbkImage );
BOOL SetBkImage( HBITMAP hbm, BOOL fTile = TRUE, int xOffsetPercent = 0, int yOffsetPercent = 0);
BOOL SetBkImage( LPTSTR pszUrl, BOOL fTile = TRUE, int xOffsetPercent = 0, int yOffsetPercent = 0 );
Return Value
Returns nonzero if successful, or zero otherwise.
Parameters
plvbkImage
Address of a LVBKIMAGE structure, containing the new background image information.
hbm
Handle to a bitmap.
pszUrl
A NULL-terminated string that contains the URL of the background image.
fTile
Nonzero if the image is to be tiled in the background of the list view control; otherwise 0.
xOffsetPercent
The offset, in pixels, of the image’s left edge, from origin of the list view control.
yOffsetPercent
The offset, in pixels, of the image’s top edge, from origin of the list view control.
Remarks
Call this function to set the background image of a list view control.
Note Because CListCtrl::SetBkImage makes use of OLE COM functionality, the OLE libraries must be initialized before using SetBkImage. It is best to initialize the COM libraries when the application is initialized and uninitialize the libraries when the application terminates. This is automatically done in MFC applications that make use of ActiveX technology, OLE Automation, OLE Linking/Embedding, or ODBC/DAO operations.
Example
See the example for CListCtrl::GetBkImage.
CListCtrl Overview | Class Members | Hierarchy Chart
See Also CListCtrl::GetBkImage