We have added search box. Key in SAP issue keyword to search
TopBottom

Announcement: wanna exchange links? contact me at sapchatroom@gmail.com.

RE:[sap-abap] How to Send Mail to Multiple Users

Posted by Admin at
Share this post:
Ma.gnolia DiggIt! Del.icio.us Yahoo Furl Technorati Reddit

Reply from Kabil on Feb 5 at 2:27 AM
These codes will help you out.

These having two options report
1.> download to a desktop
2.> send mail to multiple user report
more information, reply




* Type Group Declaration
TYPE-POOLS: slis,vrm.

* Tables Declaration
TABLES : vbak.
* Structure Declaration
TYPES: BEGIN OF ty_vbakvbap,
vbeln TYPE vbak-vbeln,
kunnr TYPE vbak-kunnr,
netpr TYPE vbap-netpr,
posnr TYPE vbap-posnr,
matnr TYPE vbap-matnr,
kwmeng TYPE vbap-kwmeng,
arktx TYPE vbap-arktx,
END OF ty_vbakvbap,
gt_t_vbakvbap TYPE STANDARD TABLE OF ty_vbakvbap.

TYPES : BEGIN OF ty_kna1,
kunnr TYPE kna1-kunnr,
name1 TYPE kna1-name1,
pstlz TYPE kna1-pstlz,
stras TYPE kna1-stras,
ort01 TYPE kna1-ort01,
land1 TYPE kna1-land1,
END OF ty_kna1,
gt_t_kna1 TYPE STANDARD TABLE OF ty_kna1.

TYPES : BEGIN OF ty_mara,
mbrsh TYPE mara-mbrsh,
matnr TYPE mara-matnr,
mtart TYPE mara-mtart,
matkl TYPE mara-matkl,
END OF ty_mara,
gt_t_mara TYPE STANDARD TABLE OF ty_mara.


TYPES : BEGIN OF ty_final,
vbeln TYPE vbak-vbeln,
kunnr TYPE vbak-kunnr,
netpr TYPE vbap-netpr,
posnr TYPE vbap-posnr,
matnr TYPE vbap-matnr,
kwmeng TYPE vbap-kwmeng,
arktx TYPE vbap-arktx,
name1 TYPE kna1-name1,
pstlz TYPE kna1-pstlz,
stras TYPE kna1-stras,
ort01 TYPE kna1-ort01,
land1 TYPE kna1-land1,
mbrsh TYPE mara-mbrsh,
mtart TYPE mara-mtart,
matkl TYPE mara-matkl,
END OF ty_final,
gt_t_final TYPE STANDARD TABLE OF ty_final.


* Sending Email structure declaration.
TYPES : t_document_data TYPE sodocchgi1,
t_packing_list TYPE sopcklsti1,
t_attachment TYPE solisti1,
t_body_msg TYPE solisti1,
t_receivers TYPE somlreci1.


* Internal Table Declaration

DATA: gt_vbakvbap TYPE gt_t_vbakvbap,
gw_vbakvbap TYPE ty_vbakvbap,
gt_kna1 TYPE gt_t_kna1,
gw_kna1 TYPE ty_kna1,
gt_mara TYPE gt_t_mara,
gw_mara TYPE ty_mara,
gt_final TYPE gt_t_final,
gw_final TYPE ty_final,
gt_fcat TYPE slis_t_fieldcat_alv,
gw_fcat TYPE slis_fieldcat_alv,
v_kunnr TYPE vbak-kunnr,

* Sub total based on the header details Sales order no. vbeln = 5006.
gt_sort TYPE slis_t_sortinfo_alv,
gw_sort TYPE slis_sortinfo_alv,



*Sending Email Declaration
*Email data declaration for select-options.
e_mail TYPE somlreci1-receiver,
*Email internal table declaration.
i_document_data TYPE TABLE OF t_document_data,
i_packing_list TYPE TABLE OF t_packing_list,
i_attachment TYPE TABLE OF t_attachment,
i_body_msg TYPE TABLE OF t_body_msg,
i_receivers TYPE TABLE OF t_receivers,
*Email work area declaration.
w_document_data TYPE t_document_data,
w_packing_list TYPE t_packing_list,
w_attachment TYPE t_attachment,
w_body_msg TYPE t_body_msg,
w_receivers TYPE t_receivers,

g_tab_lines TYPE i,
e(10) TYPE c,
gv_selected_value(10) TYPE c,

* DOC AND VRM DETAILS.
tab TYPE TABLE OF ty_final.


SELECTION-SCREEN BEGIN OF BLOCK name WITH FRAME TITLE text-001.

SELECT-OPTIONS : s_vbeln FOR vbak-vbeln DEFAULT '5006' TO '5009'.
PARAMETERS : p_kunnr TYPE kna1-kunnr.

SELECTION-SCREEN END OF BLOCK name.

SELECTION-SCREEN BEGIN OF BLOCK name1 WITH FRAME TITLE text-002.

PARAMETERS : r1 RADIOBUTTON GROUP gr1 USER-COMMAND c,
r2 RADIOBUTTON GROUP gr1.
* Selection Screen for Radio button 2

SELECTION-SCREEN

BEGIN OF BLOCK name3 WITH FRAME TITLE text-004.

SELECT-OPTIONS: mail FOR e_mail NO INTERVALS MODIF ID one.

SELECTION-SCREEN END OF BLOCK name3.


SELECTION-SCREEN END OF BLOCK name1.


INITIALIZATION.

LOOP AT SCREEN .

IF screen-group1 = 'ONE' .
screen-input = 0.
screen-invisible = 1.
MODIFY SCREEN.
ENDIF.
ENDLOOP.


AT SELECTION-SCREEN OUTPUT.
*

---------------Original Message---------------
From: jyotsna kumbhare
Sent: Monday, February 03, 2014 10:56 PM
Subject: How to Send Mail to Multiple Users

Dear friends,
Please tell me how can I send SAP mail to multiple user IDs in their SAP inbox?
The requirement is just sending SAP mail to multiple users IDs.

Thanks,
Jyotsn



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

 
Reply to this email to post your response.
 
__.____._
Manage Settings | Unsubscribe | Create FAQ | Send Feedback
  
Copyright © 2014 Ziff Davis, Inc. and message author.
Ziff Davis, Inc. 28 E 28th Street New York, NY 10016
Kabil  
 
Mark as helpful
View this online
Ask a new question
 
In the Spotlight
Become a blogger at Toolbox.com and share your expertise with the community. Start today.

_.____.__

0 comments:

Post a Comment

T r a n s l a t e to your language