cancel
Showing results for 
Search instead for 
Did you mean: 

Enhancing the ALV export option in webdynpro.

styrolution_accenture
Participant
0 Kudos

Hello Experts,

I have a requirement where in i have to enhance the possibility of exporting the ALV output data in some other format but not in excel.

as of now in webdynpro ALV output we have a option of exporting the output data in microsoft excel format and we do not see any other option in drop down.

can any one help me if this is really possible, if yes then how would we achieve this?

Thanks in advance,

RaJ.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Rajesh,

Please check this Blog..

/people/chris.paine2/blog/2010/06/11/using-wd-abap-alv-export--the-hacked-way

We have another standard option export to PDF also.

If you dont want to use Standard export to excel and to use custom button to export to anyformat.

follow this..

- convert your output data which you have in the internal table to STRING DATA.

- next convert this string data to XSTRING using the following function module SCMS_STRING_TO_XSTRING.

- use the method to export to excel or whatever is the application.

cl_wd_runtime_services=>attach_file_to_response(
     i_filename = lv_file_name
     i_content = i_content
      i_mime_type = lv_appln_type
*i_mime_type = 'x-excel/application'
     i_in_new_window = abap_false
     i_inplace = abap_false ).

Lv_appln_type is whether u want excel or word or wordpad or notepad.

cheers,

Kris.