Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
15
Row.Selected and Selected.Rows.Add behavior in Ultragrid
posted

If I select a row programmatically by setting the row's Selected property to true or by adding the row to the selected rows collection (Rows.Add or Rows.AddRange), I lose the ability to Shift+Up key or Shift+Down key to begin a multi select operation. The same is true for Shift+Left mouse click to select a range.

In addition to selecting the row, I have activated it as well.

The results I'm seeing are: Programmatically select and activate a row in the grid, Shift+Down key selects and activates the next row in the grid without preserving the selected state of the original row. Shift+Down key again will begin the multi-row select operation.

I can PerformAction(ToggleRowSel) to achieve the desired results for a singe row, but this doesn't help when I'm trying to AddRange.

I am currently running v17.2 in VS2017.

Is this the expected behavior? Is there a way to achieve the desired behavior with AddRange other than iterating the entire range and calling PerformAction on each row?

Thanks.

Parents Reply Children
No Data