Encoding EZscript Functions and Objects
Certain EZscript functions and objects support encoding formats or constants.
Encoding Functions
The following EZscript functions allow you to specify encoding formats. Some of the functions include the word Unicode, however, you can set the encoding to non-Unicode encoding types as well.
File Functions
When you use the following encoding File functions, you must use an encoding constant, or the function defaults to the machine’s default encoding scheme. This includes nesting File() functions.
The following examples show how to use the encoding parameter in File functions.
FileRead("someFile.txt", ENC_UTF8)
FileWrite("someFile.txt", someString, ENC_UTF8)
FileAppend("someFile.txt", someString, ENC_UTF8)
FileWrite("someFile.txt", FileRead("someOtherFile.txt", ENC_UTF8), ENC_UTF8)
See Also
EZscript DJMessage Objects
The following EZscript objects allow you to change encoding parameters:
• DJMessage
• DJImport
• DJExport
DJMessage variable properties do not support encoding. However, you can use a File function and a message URI handle when writing or reading from a DJMessage as shown below:
FileRead("djmessage:///someMsg", ENC_UTF8)
FileWrite("djmessage:///someMsg", someString, ENC_UTF8)
See Also