LB_SETITEMHEIGHT

3.1

LB_SETITEMHEIGHT
wParam = (WPARAM) index;        /* item index */
lParam = MAKELPARAM(cyItem, 0); /* item height */

An application sends an LB_SETITEMHEIGHT message to set the height of items in a list box. If the list box has the LBS_OWNERDRAWVARIABLE style, this message sets the height of the item specified by the wParam parameter. Otherwise, this message sets the height of all items in the list box.

Parameters

index

Value of wParam. Specifies the zero-based index of the item in the list box. This parameter is used only if the list box has the LBS_OWNERDRAWVARIABLE style; otherwise, it should be set to zero.

cyItem

Value of the low-order word of lParam. Specifies the height, in pixels, of the item.

Return Value

The return value is LB_ERR if the index or height is invalid.

Example

This example sends an LB_SETITEMHEIGHT message to set the height of the items in a list box:

LPARAM lpmHeight;

SendDlgItemMessage(hdlg, ID_MYLISTBOX, LB_SETITEMHEIGHT,
    0, lpmHeight);

See Also

LB_GETITEMHEIGHT