---
title: "index(of:)"
framework: carplay
role: symbol
role_heading: Instance Method
path: "carplay/cplistsection/index(of:)"
---

# index(of:)

Returns the index of the specified item.

## Declaration

```swift
func index(of item: any CPListTemplateItem) -> Int
```

## Parameters

- `item`: The item to find in the section.

## Return Value

Return Value The item’s index in the section, or NSNotFound if the section doesn’t contain the item.

## See Also

### Getting Items

- [items](carplay/cplistsection/items.md)
- [item(at:)](carplay/cplistsection/item(at:).md)
