如何获取datagridview 当前行的上一行

怎么获取datagridview 当前行的上一行DGVItem.CurrentRow +1应该是不行的 有没有别的方法呢[解决办法] dat

怎么获取datagridview 当前行的上一行
DGVItem.CurrentRow +1  应该是不行的 有没有别的方法呢
[解决办法]

 dataGridView1.SelectedRows[dataGridView1.CurrentRow.Index - 1]

[解决办法]
完整的应该是
int i=this.DataGridView1.CurrentCell.RowIndex;

[解决办法]
int rowIndex = this.dataGridView1.CurrentCell.RowIndex;
            DataGridViewRow dgvr = rowIndex == 0 ? null : this.dataGridView1.Rows[rowIndex];

[解决办法]

int rowIndex = this.dataGridView1.CurrentCell.RowIndex;
DataGridViewRow dgvr = rowIndex == 0 ? null : this.dataGridView1.Rows[rowIndex];