DataRowCollection.IndexOf(DataRow) 方法

定义

获取指定 DataRow 对象的索引。Gets the index of the specified DataRow object.

public:
 int IndexOf(System::Data::DataRow ^ row);
public int IndexOf (System.Data.DataRow row);
member this.IndexOf : System.Data.DataRow -> int
Public Function IndexOf (row As DataRow) As Integer

参数

row
DataRow

要搜索的 DataRowThe DataRow to search for.

返回

Int32

该行从零开始的索引;如果在集合中未找到该行,则为 -1。The zero-based index of the row, or -1 if the row is not found in the collection.

适用于