Check if data is modified


(egold2005) #1

What would be the best way to check if TDAMemDataTable has some pending changes?

function TfrmBrowseAllocation.GetSaveEnabled: Boolean;
begin
result := FALSE;
if not FDatamodule.dtAllocations.Active then exit;
if not Assigned(FDatamodule.dtAllocations.Delta) then exit;
FSaveEnabled := FDatamodule.dtAllocations.Delta.Count > 0;


(EvgenyK) #2

you are using correct way.