Replace left click behavior by ctrl-click behavior in a datagridview

I would like a DataGridView row selection to behave the same way than when holding the ctrl button down (Click a new row to add to selection, click again to deselect, etc.) But I want it using the left mouse button.

Can I set this behaviour or will I have to do it programmatically ?

Answers


I believe the DataGridView class does not support this type of behavior out of the box. In other words, you're going to have to do it yourself, which offhand does not seem all the difficult to do.


Need Your Help

Dynamically added ASP.NET button click handler being ignored

c# asp.net events

I am adding event handlers to a button like this:

Matlab - count conditioning on previous value

matlab conditional-statements probability

I have a n x m matrix, and I have associated quantiles for each column (for example for m = 3)