dev gridcontrol设置复选框列,带全选功能

1、Run Designer

2、OptionsSelection->MultiSelect=true

3、OptionsSelection->MultiSelectMode=CheckBoxRowSelect

4、代码中如何获取选中的行:

int[] SelectRows = gridView1.GetSelectedRows();

数组里面将得到Row的Index;

示例:得到ID字段的内容(注意区分大小写)

int id = Convert.ToInt32(gridView1.GetRowCellValue(index, "id"));

 

posted @ 2020-12-05 14:35  379245847  阅读(529)  评论(0)    收藏  举报