Export (0) Print
Expand All

TabControl.TabPageCollection.Item Property

Gets or sets a TabPage in the collection.

[C#] In C#, this property is the indexer for the TabControl.TabPageCollection class.

[Visual Basic]
Public Overridable Default Property Item( _
   ByVal index As Integer _
) As TabPage
[C#]
public virtual TabPage this[
 int index
] {get; set;}
[C++]
public: __property virtual TabPage* get_Item(
 int index
);
public: __property virtual void set_Item(
 int index,
   TabPage*
);
[JScript]
returnValue = TabPageCollectionObject.Item(index);
TabPageCollectionObject.Item(index) = returnValue;
-or-
returnValue = TabPageCollectionObject(index);
TabPageCollectionObject(index) = returnValue;

[JScript] In JScript, you can use the default indexed properties defined by a type, but you cannot explicitly define your own. However, specifying the expando attribute on a class automatically provides a default indexed property whose type is Object and whose index type is String.

Arguments [JScript]

index
The 0-based index of the tab page to get or set.

Parameters [Visual Basic, C#, C++]

index
The 0-based index of the tab page to get or set.

Property Value

The TabPage at the specified index.

Exceptions

Exception Type Condition
ArgumentException The value is not a TabPage.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

TabControl.TabPageCollection Class | TabControl.TabPageCollection Members | System.Windows.Forms Namespace | Add | Contains | GetEnumerator | IndexOf | RemoveAt

Show:
© 2014 Microsoft