Hi,
Is it possible to detect (or if there is an event that I am missing) the final OnRowSelected/OnRowDeselected?
I have a grid of 100 items and I am turning toolbar icons on/off depending if there are any items in the grid selected or not i.e. if one or more items selected then turn on the Delete/Move buttons, if not, disable the Delete/Move buttons.
As the events (OnRowSelected and/or OnRowDeselected) fire for each row selection change, I don't really want to call the enable/disable methods 100 times (if the user selects ALL rows) and again 100 times if they deselect all rows.
Is there an event that fires when the final select/deselect event fires so you can then process the actuall selected rows?
The work around I am using is to have a timer created on the OnRowSelected and in the OnRowDeselected - this timer has an interval of 50ms which when fires does the toolbar options. Each time the OnRowSelected/OnRowDeselected events fire they cancel the timer and create a new timer. So, if there is no events fired for 50ms I am "assuming" the events have completed and therefore perform the toolbar methods.
But this seems a bit of a hack.
Anyone got any ideas?
Thanks,
Ro
Is it possible to detect (or if there is an event that I am missing) the final OnRowSelected/OnRowDeselected?
I have a grid of 100 items and I am turning toolbar icons on/off depending if there are any items in the grid selected or not i.e. if one or more items selected then turn on the Delete/Move buttons, if not, disable the Delete/Move buttons.
As the events (OnRowSelected and/or OnRowDeselected) fire for each row selection change, I don't really want to call the enable/disable methods 100 times (if the user selects ALL rows) and again 100 times if they deselect all rows.
Is there an event that fires when the final select/deselect event fires so you can then process the actuall selected rows?
The work around I am using is to have a timer created on the OnRowSelected and in the OnRowDeselected - this timer has an interval of 50ms which when fires does the toolbar options. Each time the OnRowSelected/OnRowDeselected events fire they cancel the timer and create a new timer. So, if there is no events fired for 50ms I am "assuming" the events have completed and therefore perform the toolbar methods.
But this seems a bit of a hack.
Anyone got any ideas?
Thanks,
Ro