## List::IndexOf(const T\&) const method


Obtiene el primer índice del elemento específico.

```cpp
int System::Collections::Generic::List<T>::IndexOf(const T &item) const override
```


| Parámetro | Tipo | Descripción |
| --- | --- | --- |
| elemento | const T\& | Elemento a buscar. |

### ReturnValue

[Index](../../../system/index/) of first occurance of specified item or -1 if not found.

## Ver también

* Class [List](../)
* Namespace [System::Collections::Generic](../../)
* Library [Aspose.PDF for C++](../../../)
## List::IndexOf(const T\&, int) const method


Busca un elemento específico en la lista.

```cpp
int System::Collections::Generic::List<T>::IndexOf(const T &item, int index) const
```


| Parámetro | Tipo | Descripción |
| --- | --- | --- |
| elemento | const T\& | Elemento a buscar. |
| index | int | [Index](../../../system/index/) para iniciar la búsqueda en. |

### ReturnValue

[Index](../../../system/index/) of first instance of specified item or -1 if not found.

## Ver también

* Class [List](../)
* Namespace [System::Collections::Generic](../../)
* Library [Aspose.PDF for C++](../../../)
