IndexOf

IShapeCollection.IndexOf method

Returns the zero-based index of the first occurrence of the specified shape in the collection.

public int IndexOf(IShape shape)
ParameterTypeDescription
shapeIShapeThe shape to locate in the collection.

Return Value

The zero-based index of the first occurrence of the shape in the shape collection if found; otherwise, –1.

See Also