禁用ListView中的CheckBoxes
bool preventCheck = true;
private void listView1_ItemCheck(object sender, ItemCheckEventArgs e)
{
if (preventCheck) // for example: !string.IsNullOrEmpty(textBox1.Text)
e.NewValue = e.CurrentValue;
}
posted on 2022-05-27 09:42 qq1151219115 阅读(16) 评论(0) 编辑 收藏 举报