how to move selected row to the top of the dataGridView (c# - 2005)?

  • Thread starter Thread starter Mladen Belaj
  • Start date Start date
M

Mladen Belaj

After I select a Row with

this.dataGridView1.Rows[xRow].Selected = true;

how to move this selected row to the top of the dataGridView1? (c# - 2005)
 
Hi,

Mladen Belaj said:
After I select a Row with

this.dataGridView1.Rows[xRow].Selected = true;

how to move this selected row to the top of the dataGridView1? (c# - 2005)
Something like:

dataGridView1.FirstDisplayedCell =
dataGridView1[dataGridView1.FirstDisplayedCell.ColumnNr, xRow];
or
dataGridView1.FirstDisplayedCell = dataGridView1[0, xRow];


HTH,
Greetings
 
Back
Top