Datasnap.DBClient.TCustomClientDataSet.GetRecord
Delphi
function GetRecord(Buffer: TRecBuf; GetMode: TGetMode; DoCheck: Boolean): TGetResult; overload; override;
function GetRecord(Buffer: TRecordBuffer; GetMode: TGetMode; DoCheck: Boolean): TGetResult; overload; override; deprecated 'Use overloaded method instead';
C++
virtual Data::Db::TGetResult __fastcall GetRecord(NativeInt Buffer, Data::Db::TGetMode GetMode, bool DoCheck)/* overload */;
virtual Data::Db::TGetResult __fastcall GetRecord _DEPRECATED_ATTRIBUTE1("Use overloaded method instead") (System::PByte Buffer, Data::Db::TGetMode GetMode, bool DoCheck)/* overload */;
Properties
| Type | Visibility | Source | Unit | Parent |
|---|---|---|---|---|
| function | protected | Datasnap.DBClient.pas Datasnap.DBClient.hpp |
Datasnap.DBClient | TCustomClientDataSet |
Description
Moves to the specified record. {{#multireplace:Datasnap.DBClient.TCustomClientDataSet.GetRecord|H21=!|H25=%|H28=(|H29=)|H2A=*|H2B=+|H2F=/|H3C=<|H3D==|H3E=>|H5B=[|H5D=]|H5E=^|H7C=|}} inherits from {{#multireplace:Data.DB.TDataSet.GetRecord|H21=!|H25=%|H28=(|H29=)|H2A=*|H2B=+|H2F=/|H3C=<|H3D==|H3E=>|H5B=[|H5D=]|H5E=^|H7C=|}}. All content below this line refers to {{#multireplace:Data.DB.TDataSet.GetRecord|H21=!|H25=%|H28=(|H29=)|H2A=*|H2B=+|H2F=/|H3C=<|H3D==|H3E=>|H5B=[|H5D=]|H5E=^|H7C=|}}.
Moves to the specified record.
Use GetRecord to get the record specified by the GetMode parameter.
The Buffer parameter is a pointer to the memory location that represents the record buffer.
The GetMode parameter specifies the record retrieve mode and can take the following values:
| Value | Description |
|---|---|
|
gmCurrent |
The current record will be retrieved. |
|
gmNext |
The record after the current one will be retrieved. |
|
gmPrior |
The record prior to the current one will be retrieved. |
When the DoCheck parameter is True the method signals when an error occurs while attempting to retrieve data from the current record and returns grError.
The method returns a TGetResult value with the following significance:
| Value | Description |
|---|---|
|
grOK |
No errors occurred while attempting to retrieve data from the current record. |
|
grBOF |
Begin of file is returned when the dataset is at the beginning. |
|
grEOF |
End of file is returned when the dataset is at the end. |
|
grError |
An error occurred while attempting to retrieve data from the current record. |
Note: This method is abstract. All datasets must override it according to their need.
See Also