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

SO_OBJECT_SEND

Former Member
0 Likes
1,525

I am trying to bespoke the correspondence output, so that when it send the invoice as a PDF attachement in an email I can alos include to text in the ody of the email. The below fucntion moudle is being used to send the email, but currently there is no text in the body of the email. X_OBJCONT continas the invocie in PDF format, so can someone tell me how I add text to the body of the email.

CALL FUNCTION 'SO_OBJECT_SEND'
           EXPORTING
                OBJECT_HD_CHANGE           = X_OBJECT_HD_CHANGE
                OBJECT_TYPE                = DOCUMENT_TYPE
                ORIGINATOR                 = horiginator
                ORIGINATOR_type            = 'B'
           IMPORTING
                SENT_TO_ALL                = X_SENT_TO_ALL
           TABLES
                OBJCONT                    = X_OBJCONT
                OBJHEAD                    = X_OBJHEAD
                RECEIVERS                  = X_RECEIVERS
           EXCEPTIONS
                ACTIVE_USER_NOT_EXIST      = 1
                COMMUNICATION_FAILURE      = 2
                COMPONENT_NOT_AVAILABLE    = 3
                FOLDER_NOT_EXIST           = 4
                FOLDER_NO_AUTHORIZATION    = 5
                FORWARDER_NOT_EXIST        = 6
                NOTE_NOT_EXIST             = 7
                OBJECT_NOT_EXIST           = 8
                OBJECT_NOT_SENT            = 9
                OBJECT_NO_AUTHORIZATION    = 10
                OBJECT_TYPE_NOT_EXIST      = 11
                OPERATION_NO_AUTHORIZATION = 12
                OWNER_NOT_EXIST            = 13
                PARAMETER_ERROR            = 14
                SUBSTITUTE_NOT_ACTIVE      = 15
                SUBSTITUTE_NOT_DEFINED     = 16
                SYSTEM_FAILURE             = 17
                TOO_MUCH_RECEIVERS         = 18
                USER_NOT_EXIST             = 19
                X_ERROR                    = 20
                OTHERS                     = 21.

Edited by: showthousand on Oct 26, 2009 7:30 AM

Edited by: showthousand on Oct 26, 2009 7:31 AM

6 REPLIES 6
Read only

Former Member
0 Likes
1,071

Hi,

Are you calling this function module in some program ? or using some standard transaction for correspondance ?

Please give more details

Read only

Former Member
0 Likes
1,071

It is getitng called in the program RFKORD50 - in include RFKORI90. The email sending of the PDF attachement works fine, but I just want to add some text to the email via this function, but I can't figure out how to add any text.

Read only

0 Likes
1,071

Hi,

Had a similar requirement few months back (for a different transaction) and solved it using Implicit enhancements

Here is thread

Create a implicit enhancement at start of function module SBCOMS_SEND_REQUEST_CREATE

You need to fill Tables parameter NOTE_TEXT to get the mail body

Also in the implicit enhancement you should make sure that RFKORI90 has triggered the output. (Otherwise the body of the mail will be added to all mails from your system)

Try this out and let me know if you need help

Thanks

Read only

Former Member
0 Likes
1,071

Parameter Objcont - which is Internal Table to hold the body of the mail Line.(Text lines up to 255 characters)

This will be used to populate the text in the body of the mail.

Regards

Anand

Read only

Former Member
0 Likes
1,071

Thanks, but this parameter is already filled with the PDF attachement.

Read only

Former Member
0 Likes
1,071

I used the NOTE_TEXT parameter, but had to alos populate the receiver parameters in order for this to work: The receiver parameters require the note_num and note_start to be be populated