Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 10473

Re: ABAP Webdynpro: Showing Junk while Downloading Japanese character to Excel

$
0
0

I have got the answer, we need to pass MIME TYPE  'APPLICATION/MSEXCEL; charset=utf-16le' and add 'FFFE' in starting of hexadecimal output that we get after processing  function module SCMS_STRING_TO_XSTRING

 

code is as below:

CALL FUNCTION 'SCMS_STRING_TO_XSTRING'

       EXPORTING

         text     = text

         mimetype = lv_mimetype

*     encoding = lv_encoding

       IMPORTING

         buffer   = lv_report_xstr

       EXCEPTIONS

         failed   = 1

         OTHERS   = 2.

     IF sy-subrc = 0.

       CONCATENATE cl_abap_char_utilities=>byte_order_mark_little

       lv_report_xstr

       INTO lv_report_xstr IN BYTE MODE.

     ENDIF.


Viewing all articles
Browse latest Browse all 10473

Trending Articles