Searches for the specified object and returns the zero-based index of the last occurrence
within the range of elements in the
ObjectSet that extends
from the first element to the specified index.
Syntax
| Visual Basic (Declaration) | |
|---|
Overloads Public Function LastIndexOf( _
ByVal item As T, _
ByVal index As Integer _
) As Integer |
| Visual Basic (Usage) | Copy Code |
|---|
Dim instance As ObjectSet(Of T)
Dim item As T
Dim index As Integer
Dim value As Integer
value = instance.LastIndexOf(item, index)
|
| C# | |
|---|
public int LastIndexOf(
T item,
int index
) |
| Managed Extensions for C++ | |
|---|
public: int LastIndexOf(
T item,
int index
) |
| C++/CLI | |
|---|
public:
int LastIndexOf(
T item,
int index
) |
Parameters
- item
- The object to locate in the ObjectSet. The
value can be null for reference types.
- index
- The zero-based starting index of the backward search.
Return Value
The zero-based index of the last occurrence of item within the range of elements in
the
ObjectSet that extends from the first element to index,
if found; otherwise, -1.
Requirements
Platforms: Windows 2000, Windows XP family, Windows Server 2003 family, Windows Vista family
See Also