private void dgvCQ_CellFormatting(object sender, DataGridViewCellFormattingEventArgs e)
{
int rowindex = 0;
int currindex = 0;
if (e.RowIndex == 0)
{
if (e.ColumnIndex == 0)
{
DataGridViewCheckBoxCell cell = dgvCQ.Rows[e.RowIndex].Cells[e.ColumnIndex] as DataGridViewCheckBoxCell;
cell.ReadOnly = true;
cell.ThreeState = true; //此行设置属性出错
} }
}
datagrideviewcheckboxthreestate
{
int rowindex = 0;
int currindex = 0;
if (e.RowIndex == 0)
{
if (e.ColumnIndex == 0)
{
DataGridViewCheckBoxCell cell = dgvCQ.Rows[e.RowIndex].Cells[e.ColumnIndex] as DataGridViewCheckBoxCell;
cell.ReadOnly = true;
cell.ThreeState = true; //此行设置属性出错
} }
}
datagrideviewcheckboxthreestate
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货