The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
Hi, Which event should I use to detect when the user has multi selected rows in a GGC without using the keyboard? E.g. the user clicks a row and drags down which selects 2 or more rows, and then releases the left mouse button.
ADAdministrator Syncfusion Team January 15, 2007 11:15 AM UTC
Are you using the record selection support specific to GridGroupingControl? (ie, this.gridGroupingControl1.TableOptions.AllowSelection = GridSelectionFlags.None; this.gridGroupingControl1.TableOptions.ListBoxSelectionMode = SelectionMode.MultiExtended;
)
If so, you can use the SelectedRecordsChanging and SelectedRecordsChanged events.
JHJohn HJanuary 15, 2007 01:06 PM UTC
Thanks Clay, Another question for you though, why does SelectedRecordsChanged event get called multiple times? Even selecting a single row calls the event 5 times, 4 times with e.Table.SelectedRecords containing 0 records, and once with an add for the selected record. When selecting multiple rows an add event is triggered for each row, I just want to know the rows that are selected and act upon it. How do I do this?
Thanks John
ADAdministrator Syncfusion Team January 15, 2007 02:12 PM UTC
The RecordChanged event is called when the collection is modified. To see what is going on, you check the e.Action member of the event args. Normally, when you click on a row and start to drag, you see the event hit twice, once with e.Action = Reset and once with e.Action = Add. Then as you select more rows with your drag, you see more events with e.Action = Add.
I do not know of a simple way just to get all the selections at once. To do this this, I think you will have to replace the default selection mouse controller with your own. This will take some coding.