The String function used to format a string does not have an encoding argument to specify the encoding of the resulting string. As a result, the string returned may contain garbage characters.
To work around this issue, convert the string to a blob and then back to a string using the encoding parameters provided in the Blob and String conversion functions:
ls_temp = String(long, "address" ) // format string lb_blob = blob(ls_temp, EncodingUTF16LE!) ls_result = string(lb_blob, EncodingANSI!) // convert // to string
[CR 361568]
Copyright © 2005. Sybase Inc. All rights reserved. |
![]() |