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

email

Former Member
0 Likes
545

hi guyz,

this is program for sending email...

here i have the receiver id

gt_receiver-receiver = p_recipient.

but when the functionmodule is executed is gt_receiver is empty...plz advise

regards

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
477

hi there...

u can refer the following link to solve the query

http://www.sapdevelopment.co.uk/reporting/email/emailhome.htm

or go through the following article for sending mails through abap code::

This article focuses on ways to send E-mails and SAP Mails using ABAP code.

Firstly SAP Mail

A SAP mail is a mail internal to the SAP system. It is a very good forum to exchange information with other users. Using a SAP mail in ABAP code facilitates exchange of automatic messages at various stages of the business process. It is easy to use and saves many hassles involved in using workflows for exchanging messages.

The ABAP code to send a sap mail is built around the FM SO_OBJECT_SEND which has the following pattern.

call function 'SO_OBJECT_SEND'

exporting

  • EXTERN_ADDRESS = ' '

  • FOLDER_ID = ' '

  • FORWARDER = ' '

  • OBJECT_FL_CHANGE = ' '

  • OBJECT_HD_CHANGE = ' '

  • OBJECT_ID = ' '

  • OBJECT_TYPE = ' '

  • OUTBOX_FLAG = ' '

  • OWNER = ' '

  • STORE_FLAG = ' '

  • DELETE_FLAG = ' '

  • SENDER = ' '

  • CHECK_ALREADY_SENT = ' '

importing

object_id_new =

sent_to_all =

tables

  • OBJCONT =

  • OBJHEAD =

  • OBJPARA =

  • OBJPARB =

receivers =

  • PACKING_LIST =

  • ATT_CONT =

  • ATT_HEAD =

  • NOTE_TEXT =

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.

********************************************************************************

Do reward points if helpful or get back if have further queries .

2 REPLIES 2
Read only

Former Member
0 Likes
478

hi there...

u can refer the following link to solve the query

http://www.sapdevelopment.co.uk/reporting/email/emailhome.htm

or go through the following article for sending mails through abap code::

This article focuses on ways to send E-mails and SAP Mails using ABAP code.

Firstly SAP Mail

A SAP mail is a mail internal to the SAP system. It is a very good forum to exchange information with other users. Using a SAP mail in ABAP code facilitates exchange of automatic messages at various stages of the business process. It is easy to use and saves many hassles involved in using workflows for exchanging messages.

The ABAP code to send a sap mail is built around the FM SO_OBJECT_SEND which has the following pattern.

call function 'SO_OBJECT_SEND'

exporting

  • EXTERN_ADDRESS = ' '

  • FOLDER_ID = ' '

  • FORWARDER = ' '

  • OBJECT_FL_CHANGE = ' '

  • OBJECT_HD_CHANGE = ' '

  • OBJECT_ID = ' '

  • OBJECT_TYPE = ' '

  • OUTBOX_FLAG = ' '

  • OWNER = ' '

  • STORE_FLAG = ' '

  • DELETE_FLAG = ' '

  • SENDER = ' '

  • CHECK_ALREADY_SENT = ' '

importing

object_id_new =

sent_to_all =

tables

  • OBJCONT =

  • OBJHEAD =

  • OBJPARA =

  • OBJPARB =

receivers =

  • PACKING_LIST =

  • ATT_CONT =

  • ATT_HEAD =

  • NOTE_TEXT =

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.

********************************************************************************

Do reward points if helpful or get back if have further queries .

Read only

Former Member
0 Likes
477

Do you append to the gt_receiver table?

gt_receiver-receiver = p_receiver.

append gt_receiver.