Export (0) Print
Expand All

ImageList_LoadBitmap macro

Calls the ImageList_LoadImage function to create an image list from the specified bitmap resource.

Syntax


HIMAGELIST ImageList_LoadBitmap(
  HINSTANCE hi,
  LPCTSTR lpbmp,
  int cx,
  int cGrow,
  COLORREF crMask
);

Parameters

hi

Type: HINSTANCE

A handle to the instance that contains the bitmap resource. This parameter is NULL if you are loading an OEM bitmap.

lpbmp

Type: LPCTSTR

The image to load. If the hi parameter is non-NULL, lpbmpis the address of a null-terminated string that contains the name of the image resource in the hi module. If hi is NULL, the LOWORD of this parameter must be the identifier of an OEM bitmap to load. To create this value, use the MAKEINTRESOURCE macro with one of the OEM bitmap identifiers defined in WINUSER.H. These identifiers have the OBM_ prefix.

cx

Type: int

The width of each image. The height of each image and the initial number of images are inferred by the dimensions of the specified bitmap.

cGrow

Type: int

The number of images by which the image list can grow when the system needs to make room for new images. This parameter represents the number of new images that the resized image list can contain.

crMask

Type: COLORREF

The color used to generate a mask. Each pixel of this color in the specified bitmap is changed to black, and the corresponding bit in the mask is set to 1. If this parameter is the CLR_NONE value, no mask is generated.

Return value

Returns the handle to the image list if successful, or NULL otherwise.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Commctrl.h

 

 

Community Additions

ADD
Show:
© 2014 Microsoft