title: Unable to edit cell in DataGridView
body: <p>I have a DataGridView I'm trying to edit manually.</p>
  <p>-grid.ReadOnly is false<br />
  -all Columns ReadOnly are false<br />
  -EditMode is OnKeyStroke<br />
  -not bound to anything<br />
  -no data validation</p>
  <p>If I enter a value in the grid and then press enter or click onto another cell, the entered value disappears.</p>
  <p>I have the following events setup on the DataGridView:<br />
  CellMouseDoubleClick</p>
  <pre><code>private void trackEditor_CellMouseDoubleClick(object sender, DataGridViewCellMouseEventArgs e)
          {
              DataGridView grid = sender as DataGridView;
              //checks if the cell's value contains a 0. If so, change the value to write to 1. If not, assume the cell value is already 0 and keep the value to write to 0
              int val;
              if (grid.CurrentCell.Value == null || int.Parse(grid.CurrentCell.Value.ToString()) == 0)
                  val = 1;
              else 
                  val = 0;
              grid.CurrentCell.Value = val;
          }
  </code></pre>
  <p>CellValueChanged</p>
  <pre><code>private void trackEditor_CellValueChanged(object sender, DataGridViewCellEventArgs e)
          {
              string _out = &quot;&quot;;
              for (int x = 0; x &lt; trackEditor.ColumnCount; x++) {
                  if (trackEditor.CurrentRow.Cells[x].Value != null)
                      _out += x + &quot;:&quot; + trackEditor.CurrentRow.Cells[x].Value + &quot;,&quot;;
              }
              richRawTrackData.Text = _out;
          }
  </code></pre>