SAP ABAP Send Email with Excel Attachments

preview_player
Показать описание
This video is a SAP ABAP Tutorial to send an email with excel attachment.

Here we convert an internal table to string then to xstring and finally to BIN format
Uses below steps to send email

Build Final internal table
convert itab to string
concatenate each fields separated by #
Convert string to xstring
convert xstring to Binary format

Document Create [CL_DOCUMENT_BCS]
add attachment
Get instance of cl_bcs method create persistant
set document
Get sender instance [ CL_CAM_ADDRESS_BCS ]
Get Receiver instance method create_internet_address
Set Sender of cl_bcs
Add recipient cl_bcs
Send cl_bcs
commit work
Рекомендации по теме
Комментарии
Автор

Simply you did this ...great ...for me it took so many days to understand while I'm working...do more vedios thankyou

priyadharmana
Автор

@Code4Abap, if we are not hardcodding the sender and receiver email ids and if we want to send the attachment to multiple receivers at a time, hiw to do it?

bhavanasj
Автор

Thank you
Can you make video on how to mass download attachments in from fb60 miro purchase order attachments in

ashokb
Автор

Hi nice explanation, how to attach email in sap OData service

rachupatil
Автор

Is there any restrictions post 255 characters here. As it is with many function modules for sending emails.

ayushbhatnagar
Автор

Hi nice thanks how can i add the excel column Header?

Leben_im_Ueberfluss
Автор

I have one question that if I want to get header means coloum name or field names in email Attachment how to do that ?

nishantmainkar
Автор

Using CL_BCS, can we set excel attachment cell width according to data

udhayabanu
Автор

If your text display incorrectly just change i_type = 'TXT' to i_type = 'RAW'

redjon
Автор

Hi bro please upload videos on sap abap proxy and webservices

rowdyboy
Автор

Hi, But saw the lv_data_string having the data in the reverse order . That is not the correct way to populate into the excel . I am facing this issue now . could you please help me with it . Thanks in advance

roops_roo
Автор

Hello Bro

Please do video on How to create CSV file from alv output and attach that CSV file as email

Thanks 👍

nagendrakolusu
Автор

can u please upload the source code anywhere. just copy paste all lines

amitrane
Автор

Hii thanks but excel is not getting header description how to achieve it with header description.

rajitpatel
Автор

How to send excel file in email using guil upload

gunjangupta
Автор

LO_SEND_REQUEST IS unknown error is coming

omkarswami