This documentation is for the old version. Go to the latest Graphics Mill docs

VirtualListView.FindNearestItem Method (Int32, Int32)

Finds the item nearest to the specified coordinates. Search is supported only in icon and list modes.

Namespace: Aurigma.GraphicsMill.WinControls
Assembly: Aurigma.GraphicsMill.WinControls (in Aurigma.GraphicsMill.WinControls.dll)

Syntax

Visual Basic
Public Function FindNearestItem ( _
	x As Integer, _
	y As Integer _
) As Integer
C#
public int FindNearestItem(
	int x,
	int y
)

Parameters

x

Type: System.Int32

X-coordinate of the position to test.
y

Type: System.Int32

Y-coordinate of the position to test.

Return Value

The index of the item if successful, or -1 otherwise.

See Also

Reference