|
<< Click to Display Table of Contents >> DbiAnsiToNative |
![]() ![]()
|
C syntax
DBIResult DBIFN DbiAnsiToNative (pLdObj, pOemStr, pAnsiStr, iLen, pbDataLoss);
Delphi syntax
function DbiAnsiToNative (LdObj: Pointer; pNativeStr: PChar; pAnsiStr: PChar; iLen: Word; var bDataLoss: Bool): DBIResult stdcall;
Description
DbiAnsiToNative translates strings from ANSI to the language driver's native character set. If the native character set is ANSI, no translation takes place.
Parameters |
||
pLdObj |
Type: pVOID |
(Input) |
Pointer to the language driver object returned from DbiGetLdObj. |
||
pOemStr |
Type: pCHAR |
(Output) |
Pointer to the client buffer where the translation string is placed. If pOemStr equals pAnsiStr, conversion occurs in place. |
||
pAnsiStr |
Type: pCHAR |
(Input) |
Pointer to the client buffer containing the ANSI data. |
||
iLen |
Type: UINT16 |
(Input) |
If iLen equals 0, assumes null-terminated string; otherwise iLen specifies the length of the buffer to convert. |
||
pbDataLoss |
Type: pBOOL |
(Output) |
Pointer to a client variable. If set to TRUE, the ANSI string cannot map to a character in the native character set. |
||
Usage
Works on drivers with both ANSI and OEM native character sets. Does not handle multi-byte character sets, such as Japanese ShiftJIS. If the native character set is ANSI, no translation takes place. See International Compatibility.
DBIResult |
Meaning |
DBIERR_NONE |
The translation completed successfully. |
DBIERR_INVALIDPARAM |
A parameter passed to the function is invalid. |
DBIERR_NOTSUPPORTED |
A function is not supported by the driver. |
See also