System.Web.UI Namespace ControlCollection Class
Returns the index value that represents the position of a specified Control within the collection.
[ VB ]
Public Function IndexOf ( _
ByVal item As Control _
) As Integer
[ C# ]
public int IndexOf (
Control item
);
[ C++ ]
public: int IndexOf (
Control* item
);
[ JScript ]
public function IndexOf (
item : Control
) : int;
- item
- The Control to search for in the collection.
The index of the specified server control.
Use the IndexOf method to determine the index value of the Control specified by the item parameter in the collection. If an item with this criteria is not found in the collection, -1 is returned.
ControlCollection Members