We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

GDBG GridListControl Revisited

When processing a PopupClosedEventArgs on a GBDG with a GridListCOntrol, I''m using the following code from an earlier post to extract the selected value: GridDataBoundGrid grid = (GridDataBoundGrid) sender; GridCurrentCell cc = grid.CurrentCell; cc.EndEdit(); grid.Binder.EndEdit(); string dispMember = grid[cc.RowIndex, cc.ColIndex].FormattedText; If the GDBG DataSource returned no rows and a GridListControl record is selected from a cell on the lone empty row, this works perfect. Also, if the GridListControl record is selected on a GDBG row which has data in that cell already, the code works perfect. However,if the GDBG DataSource returned rows, and a GridListControl record is selected from a cell on the empty row following the last GBDG record, the cc.RowIndex has a negative value for the index. Thanks

4 Replies

AD Administrator Syncfusion Team June 27, 2005 06:47 PM

Are you seeing any exceptions being thrown. For example, if you have a column that does not accept nulls, then this will have to be populated before you can end the edit on teh record. Here is a little sample that seems to be working OK for me. Does it work ok for you? http://www.syncfusion.com/Support/user/uploads/GDBG_GLC_e94e2717.zip


JS John Slater June 28, 2005 04:47 AM

Clay, The supplied URL does not seem to work. >Are you seeing any exceptions being thrown. For example, if you have a column that does not accept nulls, then this will have to be populated before you can end the edit on teh record. > >Here is a little sample that seems to be working OK for me. Does it work ok for you? > >http://www.syncfusion.com/Support/user/uploads/GDBG_GLC_e94e2717.zip >


AD Administrator Syncfusion Team June 28, 2005 05:03 AM

Try this link. GDBG_GLC_6348.zip


JS John Slater June 28, 2005 05:10 AM

Also, I noticed the cc.RowIndex does not go negative until the grid.Binder.EndEdit() is called. Thanks, >Clay, > >The supplied URL does not seem to work. > >>Are you seeing any exceptions being thrown. For example, if you have a column that does not accept nulls, then this will have to be populated before you can end the edit on teh record. >> >>Here is a little sample that seems to be working OK for me. Does it work ok for you? >> >>http://www.syncfusion.com/Support/user/uploads/GDBG_GLC_e94e2717.zip >>

Loader.
Live Chat Icon For mobile
Up arrow icon