RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TCustomClientDataSet.RefreshRecord Method

Updates the base values of the current record to match the current values of the provider's dataset.

Pascal
procedure RefreshRecord;
C++
__fastcall RefreshRecord();

Call Refresh to change the base values of the current record to match the current value on the server. Refresh replaces the original values obtained from a provider, but leaves any changes in the change log intact.

Warning: RefreshRecord should be used with care. If the user has modified the current record, refreshing the original values may mask update conflicts. When the application calls ApplyUpdates, no reconcile error will occur, even where this is appropriate.
Note: A similar method, Refresh, replaces the entire contents of the client dataset with the current values supplied by the provider. Unlike RefreshRecord, which leaves unapplied changes in the change log, Refresh raises an exception when the change log is not empty.
 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!