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

Function Module to send Mail

Former Member
0 Likes
796

Hi,

Can you send the function module name to send mail from ABAP program.

KK.

7 REPLIES 7
Read only

Former Member
0 Likes
767

You can use the function module

call function 'SO_NEW_DOCUMENT_SEND_API1'

exporting

DOCUMENT_TYPE = 'RAW'

DOCUMENT_DATA = IS_DOCDATA

  • PUT_IN_OUTBOX = 'X'

COMMIT_WORK = 'X'

tables

OBJECT_CONTENT = IT_CONTENT

RECEIVERS = IT_RECEIVERS

exceptions

TOO_MANY_RECEIVERS = 1

DOCUMENT_NOT_SENT = 2

OPERATION_NO_AUTHORIZATION = 4

others = 99.

Regards

Anurag

Read only

Former Member
0 Likes
767

check this link

function module : 'SO_NEW_DOCUMENT_SEND_API1'

revert, if you need any further help.

regards

srikanth

Read only

0 Likes
767

<b>'SO_NEW_DOCUMENT_SEND_API1'</b>

Read only

Former Member
0 Likes
767

Hi Krishna,

use SO_NEW_DOCUMENT_SEND_API1 ....for sending the document as mail

SO_NEW_DOCUMENT_ATT_SEND_API1... for sending it as an attachment

Regards,

Vidya.

Read only

Former Member
0 Likes
767

hi Krishna

You can check out the FM's

SO_OBJECT_SEND

SO_NEW_DOCUMENT_SEND_API1

SO_NEW_DOCUMENT_ATT_SEND_API1

Hope this info is useful to you..

Regards,

Richa

Read only

Former Member
0 Likes
767

Hi Krishna,

Here is the FM

'SO_NEW_DOCUMENT_SEND_API1'

U can check it's documentation for more details

even a sample program is there.

Copy it and check it.

Reward points if helpful.

Regards

-


Sachin Dhingra

Read only

former_member480923
Active Contributor
0 Likes
767

Hi

Check this out

CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
         EXPORTING
              document_data              = wal_docdata
              put_in_outbox              = c_check
         TABLES
              packing_list               = t_objpack
              contents_txt               = t_content_txt
              receivers                  = t_receivers
         EXCEPTIONS
              too_many_receivers         = 1
              document_not_sent          = 2
              document_type_not_exist    = 3
              operation_no_authorization = 4
              parameter_error            = 5
              x_error                    = 6
              enqueue_error              = 7
              OTHERS                     = 8.

Hope Ths Helps

Anirban