Version

Reset a Cell’s Value History

You can reset a Cell object’s value history by calling a DataRecord object’s ResetDataValueHistory method. You can also reset the value history of multiple cells in a DataPresenter control by calling the RecordManager object’s ResetDataValueHistory method. In addition to resetting the value history of cells in a DataPresenter control, you can also retrieve the value history of a cell by calling a DataRecord object’s GetDataValueHistory method.

The following example code demonstrates how to reset the value history of all cells in a DataPresenter control. The code assumes you have a DataPresenter control named xamDataPresenter1.

In Visual Basic:

Me.xamDataPresenter1.RecordManager.ResetDataValueHistory(True)
'If you have a reference to a DataRecord object named dataRecord1 and you want to reset the value history of a single cell, use the code below and substitute "salary" with the name of a field in your DataPresenter control.
dataRecord1.ResetDataValueHistory("salary")

In C#:

this.xamDataPresenter1.RecordManager.ResetDataValueHistory(true);
//If you have a reference to a DataRecord object named dataRecord1 and you want to reset the value history of a single cell, use the code below and substitute "salary" with the name of a field in your DataPresenter control.
dataRecord1.ResetDataValueHistory("salary");