Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

funtion module to export header and item data

Former Member
0 Kudos

Hi friends,

I have two internal tables in which one is header data and other is item data.

Now i want to downlaod this data into excel file in which i need to get multiple items under each header data.

And alos i need header text display to columns names on the top in excel file.

Is there any funtion module which support this funtionality.

Could you please help me to solve this.

Thanks,

sathish

1 REPLY 1

vinod_vemuru2
Active Contributor
0 Kudos

Hi Satish,

Two options.

1. Take one more internal table(Final) and Loop at ur item table, read the header table and append the data accordingly. Finally download the data to excel using fm GUI_DOWNLOAD.

For geeting headers first download the headers only(No data).

Now call this FM again for downloading the actual data and set the FM attribute APPEND to X. Now it will append the actual data to the headers in the excel instead of overwriting the headers.

2. Display the data in Hierarchical ALV and then download to excell.

I think second option will be easier and flexible. Just u have to call 2 FMs.

Thanks,

Vinod.