2011 Nov 18 9:00 AM
Hi all,
I am using this fm SO_DOCUMENT_SEND_API1 to send an excel file to an external email. The excel file is from and internal table. The program works fine with no errors but when I received the email, the file only have 15 line items. It supposed to have 25 line items. I am not sure why this has happened from debug I see no errors and correct values were passed.
Anyone have any ideas?
Thanks.
Hi all,
I am using this fm SO_DOCUMENT_SEND_API1 to send an excel file to an external email. The excel file is from and internal table. The program works fine with no errors but when I received the email, the file only have 15 line items. It supposed to have 25 line items. I am not sure why this has happened from debug I see no errors and correct values were passed.
Anyone have any ideas?
Thanks.
2011 Nov 21 8:28 AM
Hi,
Please check whether you are passing the correct parameters in the parameter 'packing_list' for the attachment line. First line should be for the mail text/header part and next lines are for attachments. For example,
Create attachment notification for each attachment
objpack-transf_bin = 'X'. (if the attachment is passed in contents_hex)
objpack-head_start = 1.
objpack-head_num = 1.
objpack-body_start = lv_num + 1.
DESCRIBE TABLE lt_target_tab LINES objpack-body_num.
objpack-doc_size = objpack-body_num * 255.
objpack-body_num = lv_num + objpack-body_num.
lv_num = objpack-body_num.
objpack-doc_type = 'XLS'. or what ever attachment you are sending.
APPEND objpack.
Based on what you have explained here, it seems like the doc_size parameter value is passed wrongly. In debugging, see what is getting passed. Try passing a higher value & see whether there is any difference. Check body_num also.
Regards,
Gokul