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

send mail - excel attachment

Former Member
0 Likes
350

Hi ,

I am sending an excel attachment to external mail id by using Function Module SO_NEW_DOCUMENT_ATT_SEND_API1.

I am getting the mail with attachment .

But while opening iam getting a message

" the file you are trying to open is in different format . do you wat to open it? "

if we press yess , its opening properly .

i am using cl_abap_char_utilities=>horizontal_tab , cl_abap_char_utilities=>newline for formatting the data

How can i avoid the error messages coming initially

Thanks,

sar

Hi ,

I am sending an excel attachment to external mail id by using Function Module SO_NEW_DOCUMENT_ATT_SEND_API1.

I am getting the mail with attachment .

But while opening iam getting a message

" the file you are trying to open is in different format . do you wat to open it? "

if we press yess , its opening properly .

i am using cl_abap_char_utilities=>horizontal_tab , cl_abap_char_utilities=>newline for formatting the data

How can i avoid the error messages coming initially

Thanks,

sar

1 REPLY 1
Read only

LukaszPegiel
SAP Champion
SAP Champion
0 Likes
302

Hello,

the message you get is because there is no xls header , as you created simple csv file.

Try to implement SAP-Notes 1151257 & 1151258 , they helped me in same problem.

Regards

Lukasz