Applies pending updates to the dataset.
Source position: bufdataset.pas line 657
public procedure TCustomBufDataset.ApplyUpdates; virtual; overload; |
MaxErrors: Integer |
); virtual; overload; |
MaxErrors |
|
Maximum number of errors allowed before cancelling the operation. |
ApplyUpdates is an overloaded procedure used to apply pending updates for the dataset.
ApplyUpdates calls CheckBrowseMode and gets a bookmark for the current record in the dataset. The bookmark is used to return the dataset its original record after updates are applied and the dataset has been refreshed.
MaxErrors is the threshold where errors encountered in the process cause it to be aborted. The value 0 (zero) indicates no errors are allowed during the apply updates process.
ApplyUpdates uses the internal update buffers allocated for the dataset to perform the actions required in the method. The ApplyRecUpdate method is called for each of the update buffers. An exception raised in ApplyRecUpdate is handled in the method. When the value in MaxErrors is exceeded, the process is aborted. Otherwise, the update buffer is skipped. If the OnUpdateError exception handler has been assigned, it is signalled using the required arguments and its Response value is captured in the method. If the process is to be aborted, an exception is raised to indicate the condition.
When an update buffer is successfully applied, resources allocated to its OldValuesBuffer, Bookmark data, and the update buffer itself are freed. If all pending updates are applied successfully, and ManualMergeChangeLog contains False, the MergeChangeLog method is called.
ApplyUpdates calls Resync to fresh the records displayed in the dataset prior to exiting from the method.
|
Check whether the dataset is in browse mode. |
|
|
Implements a buffer used for record updates in TBufDataset. |
|
|
Event handler signalled when an error occurs while updating records. |
|
|
Indicates if the update change log can be manually merged. |
|
|
Frees update buffers and Blob update buffer allocated for the dataset. |
|
|
Resynchronize the data buffer. |