I currently have an issue with checking and unchecking a lot of checkboxes in a datagridview. I already run them parallel but its still really slow, even loading the rows in is faster...
EDIT: Issue is fixed. The AutoSizeColumnsMode
and AutoSizeRowsMode
caused it to slow down!
if (checkBox_all.Checked)
{
Parallel.ForEach(dataGrid_searchEntryList.Rows.Cast<DataGridViewRow>(), row =>
{
row.Cells[0].Value = true;
});
}
else
{
Parallel.ForEach(dataGrid_searchEntryList.Rows.Cast<DataGridViewRow>(), row =>
{
row.Cells[0].Value = false;
});
}
Any help is greatly appreciated!