TDataSet.Translate function
Transliterate a buffer.
Declaration
function Translate(Src: PAnsiChar; Dest: PAnsiChar; ToOem: Boolean)
: Integer; virtualArguments
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
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
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
