Gets or sets the object at the specified index.
Syntax
| Visual Basic (Declaration) | |
|---|
Public Default Property Item( _
ByVal index As Integer _
) As T |
| Visual Basic (Usage) | Copy Code |
|---|
Dim instance As ObjectSet(Of T)
Dim index As Integer
Dim value As T
instance.Item(index) = value
value = instance.Item(index)
|
| C# | |
|---|
public T this[
int index
]; {get; set;} |
| Managed Extensions for C++ | |
|---|
public: __property T get_Item(
int index
);
public: __property void set_Item(
int index,
T value
); |
| C++/CLI | |
|---|
public:
property T default [int] {
T get(int index);
void set (int index, T value);
} |
Parameters
- index
- The zero-based index of the object to get or set.
Exceptions
| Exception | Description |
| ArgumentOutOfRangeException | Index is less then zero or index is equal or greater
then Count. |
Requirements
Platforms: Windows 2000, Windows XP family, Windows Server 2003 family, Windows Vista family
See Also