[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'db' (#fcl)

TDataSet.Translate

Transliterate a buffer

Declaration

Source position: db.pas line 1663

public function TDataSet.Translate(

  Src: PChar;

  Dest: PChar;

  ToOem: Boolean

):Integer; virtual;

Arguments

Src

  

Source buffer

Dest

  

Destination buffer

ToOem

  

Should translation happen from native to OEM codepage or vice versa ?

Function result

Number of written bytes.

Description

Translate is called for all string fields for which the TStringField.Transliterate property is set to True. The toOEM parameter is set to True if the transliteration must happen from the used codepage to the codepage used for storage, and if it is set to False then the transliteration must happen from the native codepage to the storage codepage. This call must be overridden by descendents of TDataset to provide the necessary transliteration: TDataset just copies the contents of the Src buffer to the Dest buffer. The result must be the number of bytes copied to the destination buffer.

Errors

No checks are performed on the bufffers.

See also

TStringField.Transliterate

  

Should the field value be transliterated when reading or writing


Documentation generated on: Sep 28 2017