IDataItemContainer.DisplayIndex Property

When implemented, gets the position of the data item as displayed in a control.

Namespace: System.Web.UI
Assembly: System.Web (in system.web.dll)

int DisplayIndex { get; }
/** @property */
int get_DisplayIndex ()

function get DisplayIndex () : int

Not applicable.

Property Value

An Integer representing the position of the data item as displayed in a control.

In implementing classes such as DataGridViewColumn, the DisplayIndex property is set according to the index of the row among the displayed rows.

The following code example demonstrates an implementation of the DisplayIndex property. It is part of a larger example in the IDataItemContainer class overview topic.

int IDataItemContainer.DisplayIndex
        return _itemIndex;

Windows 98, Windows Server 2000 SP4, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0

Community Additions