Quantcast
Channel: SCN : All Content - ABAP Development
Viewing all articles
Browse latest Browse all 8332

How to Send EMAIL in CC

$
0
0


Dear team,


I have two disrtibuton list one for TO and Second for CC.


But when i send the execute the method mail is sent twice one for TO and Second for CC. Please let me know how i can proceed this.



        DATA lv_mlrec TYPE so_obj_nam VALUE 'ZAP_ERROR1'.

       DATA lv_mlrec_cc TYPE so_obj_nam VALUE 'ZAP_ERROR_CC'.

 

       lo_recipient = cl_distributionlist_bcs=>getu_persistent( " TO mail

           i_dliname = lv_mlrec

          i_private = space ).

 

 

       CALL METHOD lo_send_request->add_recipient

         EXPORTING

           i_recipient = lo_recipient.

 

       FREE lo_recipient.

 

 

 

       lo_recipient = cl_distributionlist_bcs=>getu_persistent( " CC mail

          i_dliname = lv_mlrec_cc

          i_private = space ).

 

 

       CALL METHOD lo_send_request->add_recipient

         EXPORTING

           i_recipient = lo_recipient

           i_copy      = 'X'.

 

 

* Send email

       lo_send_request->send( EXPORTING  i_with_error_screen = 'X'

                              RECEIVING  result = lv_sent_to_all ).


Viewing all articles
Browse latest Browse all 8332

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>