Data.DB.TDataSet.Close

From RAD Studio API Documentation
Jump to: navigation, search

[–] Properties
Type:
procedure
function
Visibility: public
Source:
Data.DB.pas
Data.DB.hpp
Unit: Data.DB
Parent: TDataSet

Delphi

procedure Close;

C++

void __fastcall Close();

Description

Closes a dataset.

Call Close to set the Active property of a dataset to false. When Active is false, the dataset is closed; it cannot read or write data and data-aware controls can't use it to fetch data or post edits.

An application must close the dataset before changing properties that affect the status of the database or the controls that display data in an application. For example, to change the DataSource property for a dataset, the dataset must be closed. Closing the dataset puts it into the dsInactive state.

See Also


Code Examples