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.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Problem with Event Order

Thread ID:

Created:

Updated:

Platform:

Replies:

23261 Jan 7,2005 03:04 PM UTC Jan 11,2005 02:18 PM UTC Windows Forms 7
loading
Tags: GridControl
Iain
Asked On January 7, 2005 03:04 PM UTC

Hi, I am handling a checkbox click on a databoundgrid (GridDataBoundGrid1.CheckBoxClick). If the checkbox is clicked I default values in other cells to 0: Dim grid As GridDataBoundGrid = CType(sender, GridDataBoundGrid) ''If the checkbox is deselected then we need to blank all the Commit values. If CType(grid.Model.Item(e.RowIndex(), e.ColIndex()).Text, Boolean) = True Then grid.Model.Item(e.RowIndex(), e.ColIndex() + 1).Text = "0" End If My problem is that if the last cell that I was edditing before clicking the checkbox needs to be defaulted then it fails else it works. Thanks Iain

Administrator [Syncfusion]
Replied On January 7, 2005 03:09 PM UTC

Try adding a call to ResetVolatileData to see if that helps. Dim grid As GridDataBoundGrid = CType(sender, GridDataBoundGrid) grid.ModelResetVolatileData() If CType(grid.Model.Item(e.RowIndex(), e.ColIndex()).Text, Boolean) = True Then grid.Model.Item(e.RowIndex(), e.ColIndex() + 1).Text = "0"

Iain
Replied On January 10, 2005 07:39 AM UTC

Hi Clay, Thanks for the fast response. I do not have the method "ResetVolatileData". Thanks Iain >Try adding a call to ResetVolatileData to see if that helps. > >Dim grid As GridDataBoundGrid = CType(sender, GridDataBoundGrid) >grid.ModelResetVolatileData() >If CType(grid.Model.Item(e.RowIndex(), e.ColIndex()).Text, Boolean) = True Then >grid.Model.Item(e.RowIndex(), e.ColIndex() + 1).Text = "0" >

Iain
Replied On January 10, 2005 07:40 AM UTC

Sorry.... I have found it now...Just checking to see that it works. Thanks Iain >Hi, >I am handling a checkbox click on a databoundgrid (GridDataBoundGrid1.CheckBoxClick). If the checkbox is clicked I default values in other cells to 0: > >Dim grid As GridDataBoundGrid = CType(sender, GridDataBoundGrid) > ''If the checkbox is deselected then we need to blank all the Commit values. > If CType(grid.Model.Item(e.RowIndex(), e.ColIndex()).Text, Boolean) = True Then > grid.Model.Item(e.RowIndex(), e.ColIndex() + 1).Text = "0" > > End If > >My problem is that if the last cell that I was edditing before clicking the checkbox needs to be defaulted then it fails else it works. > >Thanks > >Iain >

Iain
Replied On January 10, 2005 07:45 AM UTC

Hi again, I have found and tried this method but it still does not work. Thanks Iain >Hi, >I am handling a checkbox click on a databoundgrid (GridDataBoundGrid1.CheckBoxClick). If the checkbox is clicked I default values in other cells to 0: > >Dim grid As GridDataBoundGrid = CType(sender, GridDataBoundGrid) > ''If the checkbox is deselected then we need to blank all the Commit values. > If CType(grid.Model.Item(e.RowIndex(), e.ColIndex()).Text, Boolean) = True Then > grid.Model.Item(e.RowIndex(), e.ColIndex() + 1).Text = "0" > > End If > >My problem is that if the last cell that I was edditing before clicking the checkbox needs to be defaulted then it fails else it works. > >Thanks > >Iain >

Iain
Replied On January 11, 2005 08:34 AM UTC

Hi Clay, Have you any ideas on this one. I tried: Dim grid As GridDataBoundGrid = CType(sender, GridDataBoundGrid) grid.DataBoundGridModel.ResetVolatileData() Cheers Iain >Hi again, > >I have found and tried this method but it still does not work. > >Thanks > >Iain > >>Hi, >>I am handling a checkbox click on a databoundgrid (GridDataBoundGrid1.CheckBoxClick). If the checkbox is clicked I default values in other cells to 0: >> >>Dim grid As GridDataBoundGrid = CType(sender, GridDataBoundGrid) >> ''If the checkbox is deselected then we need to blank all the Commit values. >> If CType(grid.Model.Item(e.RowIndex(), e.ColIndex()).Text, Boolean) = True Then >> grid.Model.Item(e.RowIndex(), e.ColIndex() + 1).Text = "0" >> >> End If >> >>My problem is that if the last cell that I was edditing before clicking the checkbox needs to be defaulted then it fails else it works. >> >>Thanks >> >>Iain >>

Administrator [Syncfusion]
Replied On January 11, 2005 09:34 AM UTC

Can you upload a sample project showing the problem, or create a Direct Trac support incident with a sample project?

Iain
Replied On January 11, 2005 02:18 PM UTC

Hi Clay, I seem to have got around this by using grid.DataBoundGridModel.ConfirmPendingChanges() Thanks for all the help Iain >Hi, >I am handling a checkbox click on a databoundgrid (GridDataBoundGrid1.CheckBoxClick). If the checkbox is clicked I default values in other cells to 0: > >Dim grid As GridDataBoundGrid = CType(sender, GridDataBoundGrid) > ''If the checkbox is deselected then we need to blank all the Commit values. > If CType(grid.Model.Item(e.RowIndex(), e.ColIndex()).Text, Boolean) = True Then > grid.Model.Item(e.RowIndex(), e.ColIndex() + 1).Text = "0" > > End If > >My problem is that if the last cell that I was edditing before clicking the checkbox needs to be defaulted then it fails else it works. > >Thanks > >Iain >

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;