Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

ZIP with UTF-8

Hello,

I use the class cl_abap_zip to create the zip file and save it on the local desktop. It works correctly and the structure of the zip file is correct after unpacking. The problem appears when the name of the folder or the file inside the zip file has the German letter, for example “ß” or “ä”, in this case I get incorrect texts. I tried to convert file/folder name to UTF-8 using TREX_TEXT_TO_UTF8 but it gives again wrong results. Has anybody met similar problem?

Thank you,

Anna

Tags:
Former Member
Former Member replied

Hello Anna,

In a unicode-system you could use this function module:

SCP_REPLACE_STRANGE_CHARS

to replace the mentioned characters.

I just use it like this:

call function 'SCP_REPLACE_STRANGE_CHARS'
    exporting
      intext                  = my_text_var
    importing
      outtext                 = my_text_var.

I suppose to push your filename trough this function and do some test with it.

regards,

Sven

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question