TH
Thomas
October 1, 2003 01:14 PM UTC
Hi Asaf
The Model.SelectionChanged event is raising at least twice, because of the deselect of the old row and the select of the new row. Im using this event to build an internal list of the selected DataRows and it works for me.
Regards
Thomas
AD
Administrator
Syncfusion Team
October 1, 2003 01:50 PM UTC
Hi Asaf,
there are some internal differences the way selections are added/removed between keyboard and mouse action. But you should have all the information you need be provided by the SeclectionChangeXXX events. Make sure you do also check the GridSelectionReason of the event to handle the different scenarios that caused the event to be raised.
Stefan
AS
Asaf Segal
October 2, 2003 12:39 AM UTC
So when should I use RowEnter ?
AS
Asaf Segal
October 2, 2003 05:48 AM UTC
I checked the reason property of the selection changed event.
This event occurs number of time and not the same number in different situations.
Is there a way to know what is the last selection changed event ? ( I draw the selected objects in the grid and I get flickering because of the selection changed events that happend before the last one in each selection )
I had an idea of catching the mouse up and key up events, then I figured that I need also the mouse move event. I didn't find a way to get the "last change" when the arrow keys are pressed continuesly so there is no key up event until the end of the selection
AD
Administrator
Syncfusion Team
October 3, 2003 02:41 PM UTC
You could cache the eventargs of the last SelectionChanging or SelectionChanged event in a field in your class and then check that field in the next SelectionChanging event.
Does that help?
Stefan
AS
Asaf Segal
October 7, 2003 01:49 AM UTC
Sorry, but it doesn't.
I need to know of a new selection that came from the mouse or from the keyboard, and I don't want to get more event than I need.
My applications draws objects in a window, according to lines that are selected in the grid.
I don't care which event or events I should catch but I want to know that the selection operation has finished so I can redraw the window.
I want the window and the grid to be syncronized so if the user is draging the mouse on the grid, or continuesly pressing down key, operations that makes the selection graw, without key up / mouse up events, I still want to know that I should redraw the window.
Thanks
Asaf
AD
Administrator
Syncfusion Team
October 7, 2003 09:53 AM UTC
If you create a sample application and add comments that explain in which scenarios the eventargs (please give instructions how to reproduce) passed to SelectionChanging are not detailed enough I'll take a look and debug into it.
Stefan