05-14-2014 5:29 AM
Dear Team,
I am facing on unique Issue,When i am using FM:SO_DOCUMENT_SEND_API1,Mail is getting trigger properly with attachment but extension file is changed to some other format.please find attached herewith attachment.
When I see in SOST it is showing in excel format but in mail it is showing without extension.
Please find code piece of code for excel attachment.
OBJPACK-DOC_TYPE = 'XLS'.
OBJPACK-OBJ_NAME = 'Permit Exception List'.
Regards,
Santosh
05-14-2014 6:26 AM
05-14-2014 6:26 AM
05-14-2014 6:27 AM
Hi Santhosh,
Have you passed the document size correctly? I had used as follows:
CLEAR WA_PACKING_LIST.
WA_PACKING_LIST-TRANSF_BIN = 'X'.
WA_PACKING_LIST-HEAD_START = 0.
WA_PACKING_LIST-HEAD_NUM = 1.
WA_PACKING_LIST-BODY_START = 1.
DESCRIBE TABLE GT_ATTACH LINES WA_PACKING_LIST-BODY_NUM.
WA_PACKING_LIST-DOC_TYPE = 'XLS'.
WA_PACKING_LIST-OBJ_DESCR = ' '.
WA_PACKING_LIST-OBJ_NAME = 'AAA'.
WA_PACKING_LIST-DOC_SIZE = WA_PACKING_LIST-BODY_NUM * 255.
APPEND WA_PACKING_LIST TO LT_PACKING_LIST.
Try this way.
Regards,
Abijith
05-14-2014 7:07 AM
Hi,
Please see if you can use cl_bcs (SO_DOCUMENT_SEND_API1 is older than me..... )
Is the file a real XLS file or text file ?
If it is CSV (Create the file using the rules http://en.wikipedia.org/wiki/Comma-separated_values ) just use extension csv .
If it is tab seperator it is type txt .
Excel know how to deal with those.
sample code to use cl_bcs: see Y_R_EITAN_TEST_10_04.txt
Regards.
05-14-2014 7:21 AM
Dear Team,
First of all many thanks for the Quickie!
Instead of passing , OBJPACK-OBJ_NAME = 'Permit Exception List'(Note:in SOST it is showing excel like icon.), if i pass
OBJPACK-OBJ_NAME = 'Permit Exception List.XLS' It is working perfectly.
I am not getting why i need to pass obj_name with extension where as i am already passing
OBJPACK-DOC_TYPE = 'XLS'.
Regards,
Santosh
05-14-2014 7:34 AM
Hi,
Odd...
I have another test program for cl_bcs I do not supply in the "attachment subject" the suffix .
Regards.