Application Development and Automation 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: 
Read only

Create Excel attachment

Former Member
0 Likes
430

I have written code to create an XSL attachment to am email. It does send out the attachment in the correct format but it does not print out all the lines of output. If i have 2 lines in my output table the excel file produced contains only the first line.

I am currently using the FM SO_DOCUMENT_SEND_API1. How do I resolve this issue? Is there another FM that works better?

Thanks

Eliza

2 REPLIES 2
Read only

brad_bohn
Active Contributor
0 Likes
390

Of course, you're always better off using the most current email method - class CL_BCS if you're on NW6.0 or above. You didn't post your code, but it sounds like you're not terminating your lines properly. Are you using CL_ABAP_CHAR_UTILITIES=>CR_LF to terminate the lines and CL_ABAP_CHAR_UTILITIES=>HORIZONTAL_TAB to delimit the fields?

Read only

Former Member
0 Likes
390

Yes, I have the correct terminating condition. Somehow when I change the packing list factor from 255 to 510 it works.

t_packing_list-doc_size = t_packing_list-body_num * 510.

I do not understand why it does not work with

t_packing_list-doc_size = t_packing_list-body_num * 255.

Thanks.