NAnt SDK Documentation - v0.92 |

# OptionCollection.IndexOf Method

Retrieves the index of a specified Option object in the collection.

[Visual Basic]
Public Function IndexOf( _
ByVal item As Option _
) As Integer
[C#]
public int IndexOf(
Option item
);

#### Parameters

item
  The Option object for which the index is returned.

#### Return Value

The index of the specified Option. If the Option is not currently a member of the collection, it returns -1.

#### See Also

OptionCollection Class | NAnt.Core.Types Namespace