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

Using RFC_MAIL

Former Member
0 Likes
648

Hallo,

has anyone a Documentation or other Information

by Using the statement CALL FUNCTION 'RFC_MAIL' ...

thanks

Regards,

Dieter

Message was edited by: Dieter Gröhn

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
490

HI

GOOD

CHECK WITH THIS CODE

REPORT Z_SENDITAB_EMAIL_SREE_13424 .

tables : mara.

DATA IT_MAIL(200) TYPE C OCCURS 0 WITH HEADER LINE.

  • message body:

IT_MAIL = '1st line.'. APPEND IT_MAIL.

IT_MAIL = '2nd line.'. APPEND IT_MAIL.

IT_MAIL = '3rd line.'. APPEND IT_MAIL.

IT_MAIL = '4th line.'. APPEND IT_MAIL.

  • to view the following function (cannot be viewed in se37):

  • go to sm59, select 'TCP/IP connections',

  • select and open 'SERVER_EXEC' or 'LOCAL_EXEC',

  • look on the pull down menu SYSTEM INFORMATION->FUNCTION LIST

data : begin of itab occurs 0,

matnr like mara-matnr,

mtart like mara-mtart,

mbrsh like mara-mbrsh,

meins like mara-meins,

end of itab.

select

matnr

mtart

mbrsh

meins

from mara

into table itab.

if sy-subrc = 0.

CALL FUNCTION 'RFC_MAIL' DESTINATION 'LOCAL_EXEC'

EXPORTING USER = 'srini_paru@yahoo.com'

  • TABLES MAIL = IT_MAIL.

TABLES MAIL = ITAB.

endif.

CASE SY-SUBRC.

WHEN 0. WRITE 'E-mail sent successfully.'.

WHEN OTHERS. WRITE 'Error sending E-mail!'.

ENDCASE.

THANKS

MRUTYUN

3 REPLIES 3
Read only

Former Member
0 Likes
491

HI

GOOD

CHECK WITH THIS CODE

REPORT Z_SENDITAB_EMAIL_SREE_13424 .

tables : mara.

DATA IT_MAIL(200) TYPE C OCCURS 0 WITH HEADER LINE.

  • message body:

IT_MAIL = '1st line.'. APPEND IT_MAIL.

IT_MAIL = '2nd line.'. APPEND IT_MAIL.

IT_MAIL = '3rd line.'. APPEND IT_MAIL.

IT_MAIL = '4th line.'. APPEND IT_MAIL.

  • to view the following function (cannot be viewed in se37):

  • go to sm59, select 'TCP/IP connections',

  • select and open 'SERVER_EXEC' or 'LOCAL_EXEC',

  • look on the pull down menu SYSTEM INFORMATION->FUNCTION LIST

data : begin of itab occurs 0,

matnr like mara-matnr,

mtart like mara-mtart,

mbrsh like mara-mbrsh,

meins like mara-meins,

end of itab.

select

matnr

mtart

mbrsh

meins

from mara

into table itab.

if sy-subrc = 0.

CALL FUNCTION 'RFC_MAIL' DESTINATION 'LOCAL_EXEC'

EXPORTING USER = 'srini_paru@yahoo.com'

  • TABLES MAIL = IT_MAIL.

TABLES MAIL = ITAB.

endif.

CASE SY-SUBRC.

WHEN 0. WRITE 'E-mail sent successfully.'.

WHEN OTHERS. WRITE 'Error sending E-mail!'.

ENDCASE.

THANKS

MRUTYUN

Read only

Former Member
0 Likes
490

hi

check this link

where a person had posted an example for RFC_mail

hope this helps,

priya.

Read only

Former Member
0 Likes
490

HI Dieter,

You can check this forum thread too..

Regards,

Susmitha