471,337 Members | 1,156 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,337 software developers and data experts.

Multiple rows selected in dataGridView is not working


I have dataGridView with MultupleSelect property enabled and I programmatically set rows to be Selected based on checkbox being selected in DataGrid (code below). Issue is that it resets Selected rows each time I select a new row. What am I doing wrong?

private void dgrResults_CellContentClick(object sender, DataGridViewCellEventArgs e)
if (((DataGridView)sender).CurrentCell is DataGridViewCheckBoxCell)
dgrResults.Rows[e.RowIndex].Selected = true;

Feb 8 '06 #1
0 1384

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by David | last post: by
3 posts views Thread by manjub | last post: by
7 posts views Thread by =?Utf-8?B?TG9zdEluTUQ=?= | last post: by
6 posts views Thread by =?Utf-8?B?TU1TSkVE?= | last post: by
reply views Thread by rosydwin | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.