Runtime components : Core components : Initialization manager : Tasks : Dealing with encoding problems
  
Dealing with encoding problems
UNICOM® Digital Transformation Toolkit (UDTT™) has an XML based extensible framework and has the following methods to deal with XML file encoding problem:
If the file has BOM, then the UDTT Init Manager will ignore it when loading XML, and can justify the encoding information from BOM, and then it uses this encoding to read the file.
If no BOM or no encoding information can be found from the XML file, then the first line of the XML file will be read to find the encoding. For example, the first line of an XML file is <?xml version="1.0" encoding="UTF-8"?>, then UTF-8 is used as the encoding.
If no information can be found from first line of the XML file, then the system default encoding will be used to read file.
So the best practice to avoid encoding problem is to make the encoding of the files consistent and define the encoding in the first line of the file.
Go up to
Tasks