title: Gridview selected row show on top of gridview row automatically when i can search row
body: <p>When search row selected then selected row show on top of gridviewrow automatically with highlighted and previous data also show but selected row index change.</p>
  
  <p>Question is i have 1000 rows data in gridview when I can serach 500 row so 500 row show on top of gridview row and other data also shown in gridview.</p>
  
  <pre><code>foreach (DataGridViewRow row in dataGridView1.Rows)
  {
      if (Convert.ToInt32(row.Cells[0].Value) == Convert.ToInt32(txt_empc.Text))
      {
          row.Selected = true;
          //when search row selected then selected row show on top of gridviewrow
          //automatically with highlighted and previous data also show but selected
          //row index change
      }
  }
  </code></pre>