DEV获取GridControl当前行

//直接通过gridView获取当前行
dr=this.gridView1.GetDataRow(this.gridView1.FocusedRowHandle);
//通过DataSet获取数据,需要转换行标
dr = ds.Tables[0].Rows[this.gridView1.ViewRowHandleToDataSourceIndex(e.FocusedRowHandle)];
//通过数据绑定获取
gridcontrol1.DataSource = dt;
dr = ds.Tables[0].Rows[dt.Position];

你可能感兴趣的:(获取,dev,当前行,gridcontrol)