Data.Bind.DBScope.TCustomBindSourceDB.EmptyDataLink

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

procedure EmptyDataLink;

C++

void __fastcall EmptyDataLink();

Properties

Type Visibility Source Unit Parent
procedure
function
public
Data.Bind.DBScope.pas
Data.Bind.DBScope.hpp
Data.Bind.DBScope TCustomBindSourceDB

Description

Clears BufferCount in the DataLink connection.

You can use the EmptyDataLink method together with EmptyDataSet.

Example

The following example shows how to clear the data set and fill it with values every time the user clicks the button. This example uses the following components: TClientDataSet and TBindSourceDB with LiveBindings.

procedure TForm1.Button1Click(Sender: TObject);
begin
  ClientDataSet1.DisableControls;
  ClientDataSet1.EmptyDataSet;
  BindSourceDB1.EmptyDataLink;
  for I := 0 to 1000 do
    ClientDataSet1.AppendRecord([i * 111, i * 222]);
  ClientDataSet1.EnableControls;
end;

See Also