Good evening HashCode Chan ^^
Faced the following problem:
I need to write UTF-8 encoded strings to a text file
The program creates an XML file, storing it in this way.
WriteLn(XmlFile, ansitoutf8('<field name="Field1">привет</field>'));
However, the result is no UTF8, and when opening a file through a browser, we get errors:
Ошибка синтаксического анализа XML: некорректно Адрес: file:///G:/adverts2.xml Строка %№_строки%, символ 22: <field name="Field1"> </field> ---------------------^
what am I doing wrong?