111,126
社区成员
发帖
与我相关
我的任务
分享
private void dataGridView1_CellMouseClick(object sender, DataGridViewCellMouseEventArgs e)
{
//点击的是第一列且不是点击的标题
if (e.ColumnIndex == 0 & e.RowIndex != -1)
{
if (dataGridView1.Rows[e.RowIndex].Cells[0].Value != null)
{
dataGridView1.Rows[e.RowIndex].Cells[1].Value = dataGridView1.Rows[e.RowIndex].Cells[0].Value;
}
}
}