cancel
Showing results for 
Search instead for 
Did you mean: 

Two different excel files with same encoding not working

Former Member
0 Kudos

Hello everybody,

      I have a webdynpro application where i have export button which expprts the data and other button "empty file" which opens the empty excel file .

. and here

     if i am clicking on the "empty file" button, excel is opening and i can fill some data and import ..this is working fine. here i used ecoding format URF-8 for this button.

and when i click other button "Export" , it exports the data based on the selection and here data is coming correctly and in export button logic i used encoding "UTF-8".  and saved the exported file on to desktop and imported the same file. in this while importing this exported file through EXPORT button, i am getting some junk characters ## # # .

the code for two buttons "export" and "empty file" are same. but any one excel file is only working.But the user needs two excel files .

All the functionality of the application is workign fine. but i got stuck at this point. Its really ver urgent.

can somebody please help me on this issue.

Please find the code below  which i used for both the buttons.

  conv_out = cl_abap_conv_out_ce=>create( encoding = '4103' ).
    conv_out->convert(
      EXPORTING
        data = XTEXT "string
      IMPORTING
        buffer = STEXT ).

    wdr_task=>client_window->client->attach_file_to_response(
     i_filename = 'TEMPLATE FILE FOR ACTION MASS CREATION.xls'
     i_content stext
     i_mime_type = 'EXCEL' ).

Please help on this issue.

Thanks & Regards

Snitha

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member197475
Active Contributor
0 Kudos

Hello Snitha,

I think, this is a known case.

Even I too faced the same problem couple of months ago.

So what I did was, for Importing I used the same excel format that I have exported. Just I'll delete those entries from the exported file(type name .xls) and import the file with new entries. It works perfectly for me.

The main problem is the file type name.

Hope you got it.

BR,

RAM.