編集

次の方法で共有


DataGridViewRowCollection.GetFirstRow Method

Definition

Gets the first row in the collection that meets the specified criteria.

Overloads

GetFirstRow(DataGridViewElementStates)

Returns the index of the first DataGridViewRow that meets the specified criteria.

GetFirstRow(DataGridViewElementStates, DataGridViewElementStates)

Returns the index of the first DataGridViewRow that meets the specified inclusion and exclusion criteria.

GetFirstRow(DataGridViewElementStates)

Source:
DataGridViewRowCollection.cs
Source:
DataGridViewRowCollection.cs
Source:
DataGridViewRowCollection.cs

Returns the index of the first DataGridViewRow that meets the specified criteria.

public:
 int GetFirstRow(System::Windows::Forms::DataGridViewElementStates includeFilter);
public int GetFirstRow (System.Windows.Forms.DataGridViewElementStates includeFilter);
member this.GetFirstRow : System.Windows.Forms.DataGridViewElementStates -> int
Public Function GetFirstRow (includeFilter As DataGridViewElementStates) As Integer

Parameters

includeFilter
DataGridViewElementStates

A bitwise combination of DataGridViewElementStates values.

Returns

The index of the first DataGridViewRow that has the attributes specified by includeFilter; -1 if no row is found.

Exceptions

includeFilter is not a valid bitwise combination of DataGridViewElementStates values.

See also

Applies to

GetFirstRow(DataGridViewElementStates, DataGridViewElementStates)

Source:
DataGridViewRowCollection.cs
Source:
DataGridViewRowCollection.cs
Source:
DataGridViewRowCollection.cs

Returns the index of the first DataGridViewRow that meets the specified inclusion and exclusion criteria.

public:
 int GetFirstRow(System::Windows::Forms::DataGridViewElementStates includeFilter, System::Windows::Forms::DataGridViewElementStates excludeFilter);
public int GetFirstRow (System.Windows.Forms.DataGridViewElementStates includeFilter, System.Windows.Forms.DataGridViewElementStates excludeFilter);
member this.GetFirstRow : System.Windows.Forms.DataGridViewElementStates * System.Windows.Forms.DataGridViewElementStates -> int
Public Function GetFirstRow (includeFilter As DataGridViewElementStates, excludeFilter As DataGridViewElementStates) As Integer

Parameters

includeFilter
DataGridViewElementStates

A bitwise combination of DataGridViewElementStates values.

excludeFilter
DataGridViewElementStates

A bitwise combination of DataGridViewElementStates values.

Returns

The index of the first DataGridViewRow that has the attributes specified by includeFilter, and does not have the attributes specified by excludeFilter; -1 if no row is found.

Exceptions

One or both of the specified filter values is not a valid bitwise combination of DataGridViewElementStates values.

See also

Applies to