Set CopiaFacts Text-file Encoding

$unicode filetype encoding

This command sets the CopiaFacts default encoding for writing command files and other text files.  Without this command, CopiaFacts continues to write such files using the system default encoding set by Windows.  Multiple commands may be used and later commands supersede earlier ones if the filetype overlaps.

This command has no effect on the reading of command files and other text files, which are assumed to be encoded in the system default code page unless identified as Unicode by the presence of a byte order mark preamble (BOM).

The parameters on this command are used as follows:

filetype one of the following keywords to specify the files to be affected by the command:
CFGfileThe FAXFACTS.CFG file.  If you change the encoding specified for this file in COPIAEDIT, it will be saved with the new encoding.
USRfile, UJPfileAll USR and UJP files
FSfileAll FS files and FS template files
IIFfileAll IIF (infobox) files
GCTfileAll GCT files.  Note that if this encoding is specified as any Unicode type, the GCT file embedded in a GTT file will be encoded as UTF-8.  This value must be set to UTF-8 if you wish to apply non-ASCII annotations to faxes.  You will also of course require a Unicode or UTF-8 setting for the files which contain the text or variable values to be applied.
MBXfileAll MBX files
MCFfileAll MCF files
AllCommandFilesAll the above file types
JobFieldListJob Field Lists for WordMerge.  It is recommended that you use Unicode or UTF8 encoding for this file.
JobHistoryJob History Log files
JobExtractJob Extracted Data (.TAB).  For very large jobs, Unicode encoding will give a performance gain and will require less memory.
JobStdReptJob Standard Report Files
AllJobFilesAll of the four file types above which relate to job administration.
ActiveFiles written in the ACTIVE folder. This setting cannot be a two-byte Unicode encoding.
EMailBodyE-Mail body text files written from the CopiaFacts Workstation Client and CopiaFacts SMTP Gateway.
EMailHTMLBodyE-Mail body text files written from the CopiaFacts SMTP Gateway.
EMailRecipListE-Mail body recipient lists written from the CopiaFacts SMTP Gateway.
TraceFile*.TR? and *.FT? trace files. UTF8 is the default setting.  Setting a value of default causes trace files still to be written with utf-8 encoding, but without a byte-order mark (BOM).  Note that if this encoding is specified as any Unicode type, the trace files will actually be encoded as UTF-8 (because of the very large size of some trace files). Important: see Changing Trace File Encoding if you change this setting.
AllAll of the above file types
encoding one of the following keywords to describe the required encoding:
DefaultThe system default encoding.  This is the default for file types not included on any command. You can use this setting to override an earlier command which sets encoding for a group of file types.
ASCIIThis limits output to ASCII characters (values 32 to 126)
Unicode, UTF16This writes one or more two-byte values for each character.  Files written with this encoding cannot be processed with CopiaFacts version 7 or earlier. Files are written with a UTF-16 Unicode byte order mark preamble (BOM).
UTF8This writes one byte for every ASCII character, and one or more bytes for other characters. Files are written with a UTF-8 Unicode byte order mark preamble (BOM).  Files written with this encoding cannot be processed with CopiaFacts engine versions earlier than 7.330, and only with later version-7 releases for special applications.

When Unicode output is not specified in CopiaFacts version 8:

Programs write all command files in system default encoding (no byte order mark is needed). Trace files are always written with utf-8 encoding.

All command files with no BOM are treated as encoded with the system default character set.

Command files generated externally with a Unicode BOM are accepted, but if written out will be converted to the system default character set, possibly with data loss. For this reason, the use of Unicode command files is not recommended unless Unicode output is also specified for the file type.

When Unicode output is specified in CopiaFacts version 8:

Programs write the specified files in UTF-8 or UTF-16 encoding, with BOM

All command files with no BOM are treated as encoded with the system default character set.

Command files generated externally with a Unicode BOM are accepted, but if written out will be converted to the specified encoding.

Your own applications which process CopiaFacts command files must be capable of handling UTF-8 and/or UTF-16 encoding and files which have a BOM.

Programs still in use from earlier CopiaFacts releases must be replaced with version 8 releases.

Examples:

$unicode GCTfile UTF8       ; allow Unicode annotations to be saved

$unicode TraceFile UTF8     ; trace files will be UTF8-encoded