GetItem Method
Collapse the table of content
Expand the table of content

IGridProvider.GetItem Method

This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Retrieves the UI automation provider for the specified cell.

Namespace:  System.Windows.Automation.Provider
Assembly:  System.Windows (in System.Windows.dll)

IRawElementProviderSimple GetItem(
	int row,
	int column


Type: System.Int32
The ordinal number of the row that contains the cell.
Type: System.Int32
The ordinal number of the column that contains the cell.

Return Value

Type: System.Windows.Automation.Provider.IRawElementProviderSimple
The UI automation provider for the specified cell.

Grid coordinates are zero-based. The upper-left cell (or upper-right cell, depending on locale) has coordinates (0,0).

If a cell is empty, a UI Automation provider must still be returned in order to support the ContainingGrid property for that cell. This is possible when the layout of child elements in the grid is similar to a ragged array.

Hidden rows and columns can be loaded in the tree, depending on the provider implementation. Therefore, they will be reflected in the RowCount and ColumnCount properties. If the hidden rows and columns have not yet been loaded, they should not be counted.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

© 2017 Microsoft