ListBox_SetTopIndex macro (windowsx.h)

Ensures that the specified item in a list box is visible. You can use this macro or send the LB_SETTOPINDEX message explicitly.

Syntax

void ListBox_SetTopIndex(
   hwndCtl,
   indexTop
);

Parameters

hwndCtl

Type: HWND

A handle to the control.

indexTop

Type: int

The zero-based index of the item to put at the top of the visible part of the list.

Return value

None

Remarks

The list box contents are scrolled so that either the specified item appears at the top of the list box or the maximum scroll range has been reached.

Requirements

Requirement Value
Minimum supported client Windows Vista [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header windowsx.h