Base:
property
State
System.Windows.Forms.DataGridViewElement.State
1 override of State
System.Windows.Forms.Tests (1)
System\Windows\Forms\DataGridViewRowTests.cs (1)
5759public override DataGridViewElementStates State => StateResult;
6 writes to State
System.Windows.Forms (6)
System\Windows\Forms\Controls\DataGridView\DataGridViewRowCollection.cs (6)
131dataGridViewRow.State = SharedRowState(index); 140newDataGridViewRow.State = SharedRowState(index); 212dataGridViewRow.State |= DataGridViewElementStates.Visible; 674dataGridViewRow.State = DataGridViewElementStates.None; 1713dataGridViewRow.State = DataGridViewElementStates.None; 2422SharedRow(rowIndex).State = SharedRowState(rowIndex);
51 references to State
System.Windows.Forms (30)
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (1)
11079OnAddingRow(dataGridViewRow, dataGridViewRow.State, checkFrozenState: false);
System\Windows\Forms\Controls\DataGridView\DataGridViewCell.cs (6)
163Debug.Assert(DataGridView.Rows.GetRowState(RowIndex) == DataGridView.Rows.SharedRow(RowIndex).State); 265Debug.Assert(DataGridView.Rows.GetRowState(RowIndex) == DataGridView.Rows.SharedRow(RowIndex).State); 444Debug.Assert(DataGridView.Rows.GetRowState(RowIndex) == DataGridView.Rows.SharedRow(RowIndex).State); 514Debug.Assert(DataGridView.Rows.GetRowState(RowIndex) == DataGridView.Rows.SharedRow(RowIndex).State); 546Debug.Assert(DataGridView.Rows.GetRowState(RowIndex) == DataGridView.Rows.SharedRow(RowIndex).State); 751Debug.Assert(DataGridView.Rows.GetRowState(RowIndex) == DataGridView.Rows.SharedRow(RowIndex).State);
System\Windows\Forms\Controls\DataGridView\DataGridViewRow.cs (1)
323throw new InvalidOperationException(string.Format(SR.DataGridView_InvalidPropertyGetOnSharedRow, nameof(State)));
System\Windows\Forms\Controls\DataGridView\DataGridViewRowCollection.cs (22)
210Debug.Assert((dataGridViewRow.State & (DataGridViewElementStates.Selected | DataGridViewElementStates.Displayed)) == 0); 233DataGridViewElementStates rowState = dataGridViewRow.State; 264Debug.Assert(dataGridViewRow.State == SharedRowState(index)); 350DataGridViewElementStates rowTemplateState = rowTemplate.State; 417DataGridView.OnAddingRow(dataGridViewRow, dataGridViewRow.State, checkFrozenState: true); // will throw an exception if the addition is illegal 440Debug.Assert((dataGridViewRow.State & (DataGridViewElementStates.Selected | DataGridViewElementStates.Displayed)) == 0); 441_rowStates.Add(dataGridViewRow.State); 453Debug.Assert(dataGridViewRow.State == SharedRowState(index)); 690DataGridViewElementStates rowState = rowTemplate.State & ~(DataGridViewElementStates.Selected | DataGridViewElementStates.Displayed); 766Debug.Assert((dataGridViewRow.State & (DataGridViewElementStates.Selected | DataGridViewElementStates.Displayed)) == 0); 767_rowStates.Add(dataGridViewRow.State); 774Debug.Assert(dataGridViewRow.State == SharedRowState(index)); 1431DataGridViewElementStates rowTemplateState = rowTemplate.State; 1519DataGridView.OnInsertingRow(rowIndex, dataGridViewRow, dataGridViewRow.State, ref newCurrentCell, true, 1, force); // will throw an exception if the insertion is illegal 1541Debug.Assert((dataGridViewRow.State & (DataGridViewElementStates.Selected | DataGridViewElementStates.Displayed)) == 0); 1542_rowStates.Insert(rowIndex, dataGridViewRow.State); 1554Debug.Assert(dataGridViewRow.State == SharedRowState(rowIndex)); 1724DataGridViewElementStates rowState = rowTemplate.State & ~(DataGridViewElementStates.Selected | DataGridViewElementStates.Displayed); 1815Debug.Assert((dataGridViewRow.State & (DataGridViewElementStates.Selected | DataGridViewElementStates.Displayed)) == 0); 1816_rowStates.Insert(rowIndexInserted, dataGridViewRow.State); 1825Debug.Assert(dataGridViewRow.State == SharedRowState(rowIndexInserted)); 2228_rowStates[index] = dataGridViewRow.State;
System.Windows.Forms.Tests (21)
System\Windows\Forms\DataGridViewRowTests.cs (21)
45Assert.Equal(DataGridViewElementStates.Visible, row.State); 1175Assert.Equal(value, (row.State & DataGridViewElementStates.Frozen) != 0); 1180Assert.Equal(value, (row.State & DataGridViewElementStates.Frozen) != 0); 1185Assert.Equal(!value, (row.State & DataGridViewElementStates.Frozen) != 0); 1201Assert.Equal(value, (row.State & DataGridViewElementStates.Frozen) != 0); 1207Assert.Equal(value, (row.State & DataGridViewElementStates.Frozen) != 0); 1213Assert.Equal(!value, (row.State & DataGridViewElementStates.Frozen) != 0); 1238Assert.Equal(value, (row.State & DataGridViewElementStates.Frozen) != 0); 1247Assert.Equal(value, (row.State & DataGridViewElementStates.Frozen) != 0); 1256Assert.Equal(!value, (row.State & DataGridViewElementStates.Frozen) != 0); 2555Assert.Equal(value, (row.State & DataGridViewElementStates.ReadOnly) != 0); 2560Assert.Equal(value, (row.State & DataGridViewElementStates.ReadOnly) != 0); 2565Assert.Equal(!value, (row.State & DataGridViewElementStates.ReadOnly) != 0); 3063Assert.Equal(DataGridViewElementStates.Visible, row.State); 3075Assert.Throws<InvalidOperationException>(() => row.State); 3263Assert.Equal(value, (row.State & DataGridViewElementStates.Visible) != 0); 3268Assert.Equal(value, (row.State & DataGridViewElementStates.Visible) != 0); 3273Assert.Equal(!value, (row.State & DataGridViewElementStates.Visible) != 0); 3289Assert.Equal(value, (row.State & DataGridViewElementStates.Visible) != 0); 3295Assert.Equal(value, (row.State & DataGridViewElementStates.Visible) != 0); 3301Assert.Equal(!value, (row.State & DataGridViewElementStates.Visible) != 0);