ListView.GetItemRect Method (Int32)

Retrieves the bounding rectangle for a specific item within the list view control.

Namespace: System.Windows.Forms
Assembly: System.Windows.Forms (in system.windows.forms.dll)

public Rectangle GetItemRect (
	int index
)
public Rectangle GetItemRect (
	int index
)
public function GetItemRect (
	index : int
) : Rectangle

Parameters

index

The zero-based index of the item within the ListView.ListViewItemCollection whose bounding rectangle you want to return.

Return Value

A Rectangle that represents the bounding rectangle of the specified ListViewItem.

The bounding rectangle returned by this version of the GetItemRect method represents the entire item, including the icon, item text, and subitem text. To specify a specific portion of the item's bounding rectangle, use the other version of the GetItemRect method.

Windows 98, Windows 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see System Requirements.

.NET Framework

Supported in: 2.0, 1.1, 1.0

Community Additions

ADD
Show: