cancel
Showing results for 
Search instead for 
Did you mean: 

SO_NEW_DOCUMENT_SEND_API1

Former Member

Hi All,

Can i use this FM in my ABAP report.

If i can, what are all the inputs in below my ??? .

CALL FUNCTION 'SO_NEW_DOCUMENT_SEND_API1'

EXPORTING

DOCUMENT_DATA = ???

  • DOCUMENT_TYPE = 'RAW'

  • PUT_IN_OUTBOX = ' '

  • COMMIT_WORK = ' '

  • IMPORTING

  • SENT_TO_ALL =

  • NEW_OBJECT_ID =

TABLES

  • OBJECT_HEADER =

  • OBJECT_CONTENT =

  • CONTENTS_HEX =

  • OBJECT_PARA =

  • OBJECT_PARB =

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

.

IF SY-SUBRC <> 0.

  • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

  • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ENDIF.

Regards,

Soni

Accepted Solutions (0)

Answers (3)

Answers (3)

former_member184495
Active Contributor

Hi Soni,

yes u can use it .

main parameters are

document type = 'RAW'

commit_work = 'X'

object_header = '<any text>'

object_content = '<mail subject>'

receivers = <internal table where u store email-address>

Please reward for worth answers, as you havent rewarded your other threads.

Hope it helps.

Aditya.

Former Member
0 Kudos

Hi Aditya,

But here my case is different, I need to send this attachement mail to SAP Users only.

No need to send EMAIL.

Is it possible SAP User to send attachement to another SAP User using this FM?

Regards,

Soni

Former Member
0 Kudos

Hi, if u want to send message from one sap user to another,

u can use function SO_DYNP_SHORT_MESSAGE,

to send mesasage in background with attachments use SO_NEW_DOCUMENT_ATT_SEND_API1.

in your case l_RECEIVERS-REC_TYPE = 'B' (SAP User)

l_RECEIVERS-RECEIVER = user login.

former_member184495
Active Contributor
0 Kudos

Hi SN,

if you want to send attachments then use FM that our friend OM suggested,

SO_NEW_DOCUMENT_ATT_SEND_API1.

Cheers,

Aditya.

Former Member
0 Kudos

Hi,

But this FM through RFC.

No simple i need an attachement as SAP report out put.

I don't want in Excel sheet and Word..

Pls help me on this

Regards,

Soni

Former Member
0 Kudos

This message was moderated.

Former Member

l_DOCUMENT_DATA-OBJ_NAME = 'Name of Document'.

l_DOCUMENT_DATA-OBJ_DESCR = 'Document Description'.

l_DOCUMENT_DATA-OBJ_LANGU = language

l_DOCUMENT_DATA-OBJ_PRIO - priority

etc...

l_RECEIVERS-RECEIVER - name of receiver

l_RECEIVERS-REC_TYPE - type (B -sap user, O -sap ofiice user, U - internet adress, etc...)

APPEND l_receivers TO t_receivers.

Former Member
0 Kudos

Sorry, In any ABAP report