ADAdministrator Syncfusion Team June 30, 2003 04:44 PM
Try SelectionChanging or SelectionChanged.
GRgrerJuly 1, 2003 07:48 AM
OH, I'm using a gridDataboundGrid. That events is not in this grid. Could you suggest another event method for the grid databound grid.
ADAdministrator Syncfusion Team July 1, 2003 04:57 PM
The SelectionChanging/SelectionChanged events are members of the GridDataBoundGrid.Model class.
You can get at this event from the GridDataBoundGrid.Model.SelectionChanged. In C#, you would use this.gridDataBoundGrid1.Model.SelectionChanged += ... and in VB you would use Addhandler me.gridDataBoundGrid1.Model.SelectionChanged, addressof .....
GRgrerJuly 2, 2003 08:14 AM
GRgrerJuly 24, 2003 04:14 AM
The GDBG.Model.SelectionChanged event fires when the user selects a row in the grid but the selections.count is zero initially then the user has to select the row/cell a second time for the selections collection to have items. After the second time the grid selection works fine. Is this a bug?
ADAdministrator Syncfusion Team July 24, 2003 06:38 AM
This event will fire when selections are removed also. For example, if you are using ListBoxMode, then when you click another row, this event is hit twice, once to remove the original selection and once to add the new selection. You can test e.Range to distinguish these case as e.Range is empty when a selection is being removed.
If this does not explain what you are seeing, can you post a little sample project showing the problem, or tell us how to see it in one of the samples we ship?
GRgrerJuly 25, 2003 09:44 AM
HEre is the code added to one of your samples. Just click on the grid when the form opens.
ADAdministrator Syncfusion Team July 25, 2003 11:26 AM
If you add this to the formload, you will not see your message.
this.gridDataBoundGrid1.ForceCurrentCellMoveTo = true;
The reason is that initially, there was no current cell. And your code is considering the currentcell as a selection.
GRgrerJuly 25, 2003 12:27 PM
so if there are multiple grids. I have to set all the grids with a current cell and this will keep for each grid?
ADAdministrator Syncfusion Team July 25, 2003 12:30 PM