Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • create utf-8 xml file with tabmult

    Hi everyone,

    I create a .xml file with various sheets which I later on open in Excel. One sheet has Strings which are whole sentences in german (from an online questionnaire). Hence it sometimes contains letters like "ä", "ö", "ü" and "ß".

    As soon as the xml is created, these letters are not displayed correctly anymore. I realized, that the xml starts with
    Code:
    <?xml version='1.0' encoding='ISO-8859-1'?>
    and I guess there should be a way to start the xml with the correct encoding (utf-8).

    So, my question- is there an option that I can add to the tabmult command to create the xml with another encoding?

    My tabmult command:

    Code:
    tabmult, cat(Teilnahme) by (Tranche) sc sr save("xxxx\Path\Name.xml") sheet(01_XXXX) replace
    tabmult if Teilnahme == "Teilnahme", cat(Kurs) by (Tranche) sc sr save("xxxx\Path\Name.xml") sheet(02_XXXX) append
    tabmult if Tranche == "2", cat(b004_01) by (Kursart) sc sr save("xxxx\Path\Name.xml") sheet(03_XXXX) append
    tabmult if Tranche == "2", cat(b006_01) by (Kursart) sc sr save("xxxx\Path\Name.xml") sheet(04_XXXX) append
    I use STATA 16 on the OS W10
Working...
X