[]
        
(Showing Draft Content)

C1.Excel.XLExternalBookCollection.IndexOf

IndexOf Method

IndexOf(XLExternalBook)

Gets the index of a given XLExternalBook in the collection.

Declaration
public int IndexOf(XLExternalBook sheet)
Parameters
Type Name Description
XLExternalBook sheet

The object to look for.

Returns
Type Description
int

The index of the object in the collection, or -1 if the object is not a member of the collection.

IndexOf(string)

Gets the position of the sheet with the specified name in the collection.

Declaration
public int IndexOf(string fileName)
Parameters
Type Name Description
string fileName

Name of the object to look for (case-insensitive).

Returns
Type Description
int

The index of the sheet in the collection, or -1 if the sheet can't be found in the collection.