Exporting Email to SAP Employee
I'm using the Microsoft Web Service MA to synchronize with SAP. I've modified the example workflows for import and can successfully import data from Employee and User objects, but when I try to export an Email to an Employee (again by modifying the example)
I'm hitting the following:
"Microsoft.MetadirectoryServices.ExtensibleExtensionException: Sequence contains no matching element ---> System.InvalidOperationException: Sequence contains no matching element
at System.Linq.Enumerable.Single[TSource](IEnumerable`1 source, Func`2 predicate)
at Microsoft.VisualBasic.Activities.VisualBasicValue`1.GetValueCore(ActivityContext context)
at Microsoft.VisualBasic.Activities.VisualBasicValue`1.TryGetValue(ActivityContext context, TResult& value)
at System.Activities.InArgument`1.TryPopulateValue(LocationEnvironment targetEnvironment, ActivityInstance activityInstance, ActivityContext resolutionContext)
at System.Activities.ActivityInstance.ResolveArguments(ActivityExecutor executor, IDictionary`2 argumentValueOverrides, Location resultLocation, Int32 startIndex)
at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation)
--- End of inner exception stack trace ---
at Microsoft.IdentityManagement.MA.WebServices.ExportStrategy.PutExportEntries(IList`1 csEntries)
at Microsoft.IdentityManagement.MA.WebServices.WebServiceManagementAgent.PutExportEntries(IList`1 csentries)
Forefront Identity Manager 4.1.3599.0"
Has anyone seen this before, or got the WS MA to export Email to an Employee?
Ta,
Dave
I'm using the Microsoft Web Service MA to synchronize with SAP. I've modified the example workflows for import and can successfully import data from Employee and User objects, but when I try to export an Email to an Employee (again by modifying the example)
I'm hitting the following:
"Microsoft.MetadirectoryServices.ExtensibleExtensionException: Sequence contains no matching element ---> System.InvalidOperationException: Sequence contains no matching element
at System.Linq.Enumerable.Single[TSource](IEnumerable`1 source, Func`2 predicate)
at Microsoft.VisualBasic.Activities.VisualBasicValue`1.GetValueCore(ActivityContext context)
at Microsoft.VisualBasic.Activities.VisualBasicValue`1.TryGetValue(ActivityContext context, TResult& value)
at System.Activities.InArgument`1.TryPopulateValue(LocationEnvironment targetEnvironment, ActivityInstance activityInstance, ActivityContext resolutionContext)
at System.Activities.ActivityInstance.ResolveArguments(ActivityExecutor executor, IDictionary`2 argumentValueOverrides, Location resultLocation, Int32 startIndex)
at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation)
--- End of inner exception stack trace ---
at Microsoft.IdentityManagement.MA.WebServices.ExportStrategy.PutExportEntries(IList`1 csEntries)
at Microsoft.IdentityManagement.MA.WebServices.WebServiceManagementAgent.PutExportEntries(IList`1 csentries)
Forefront Identity Manager 4.1.3599.0"
Has anyone seen this before, or got the WS MA to export Email to an Employee?
Ta,
Dave
Similar Messages
-
Reg: HRforms converted to PDF and send email to individual employee
Hi Experts,
The requirement is convert the HR form output to pdf and send email to respective employee in standard transaction. I copied RPCEDTX0 to ZRPCEDTX0 and include RPCEDS09 to ZRPCEDS09, the changes need to be done for individual PERNR, I have modified the include as shown below.
CALL FUNCTION 'HRPY_PROCESS_SET_PERNR_STATUS' after this, i have written my code
* start of changes ARAFIQUE
DATA: formname TYPE tdsfname VALUE 'HR_ESS_PAYSLIP_TO_PDF',
fm_name TYPE rs38l_fnam,
pinfo LIKE pc407 OCCURS 0 WITH HEADER LINE,
pform type tt_pc408,
pform_l like pc408 OCCURS 0 WITH HEADER LINE.
IF xform[] IS NOT INITIAL.
pform_l = xform.
APPEND pform_1 TO pform.
pinfo-molga = '99'.
pinfo-forml = 'ZACC'.
APPEND pinfo.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = formname
* VARIANT = ' '
* DIRECT_CALL = ' '
IMPORTING
fm_name = fm_name
EXCEPTIONS
no_form = 1
no_function_module = 2
OTHERS = 3
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
CALL FUNCTION fm_name
EXPORTING
pinfo =
pform = xform[]
EXCEPTIONS
FORMATTING_ERROR = 1
INTERNAL_ERROR = 2
SEND_ERROR = 3
USER_CANCELED = 4
OTHERS = 5
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDIF.
* end of changes ARAFIQUE
I found out in internet that the smartform 'HR_ESS_PAYSLIP_TO_PDF' will convert to PDF and then i can send email to PERNRS.Hi Experts,
I have written the below code, the payslip is getting converted to PDF and it is getting saved in presentation server. I need to pick this file and mail, I created a customized function module for sending mail. I'm not able to send email to external addresses.
Please find my code below. I will post the function module later.
* start of changes ARAFIQUE
DATA: "formname TYPE tdsfname VALUE 'HR_ESS_PAYSLIP_TO_PDF',
"fm_name TYPE rs38l_fnam,
p_info LIKE pc407 OCCURS 0 WITH HEADER LINE,
"pform type tt_pc408,
p_form LIKE pc408 OCCURS 0 WITH HEADER LINE,
pdf_content TYPE xstring,
pdf_fsize TYPE i,
lv_output_length TYPE i,
lt_binary_data TYPE STANDARD TABLE OF sdokcntbin,
it_receivers LIKE somlreci1 OCCURS 0 WITH HEADER LINE,
it_message LIKE solisti1 OCCURS 0 WITH HEADER LINE.
IF xform[] IS NOT INITIAL.
p_form[] = xform[].
p_info-molga = '99'.
p_info-forml = 'ZACC'.
p_info-pcols = 1.
p_info-psize = 1.
APPEND p_info.
CALL FUNCTION 'CONVERT_PAYSLIP_TO_PDF'
EXPORTING
p_info = p_info
IMPORTING
pdf_content = pdf_content
pdf_fsize = pdf_fsize
TABLES
p_form = p_form[]
EXCEPTIONS
empty_form = 1
OTHERS = 2.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
EXPORTING
buffer = pdf_content
IMPORTING
output_length = lv_output_length
TABLES
binary_tab = lt_binary_data.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
filename = 'C:\Test\Testing.pdf'
filetype = 'BIN'
TABLES
data_tab = lt_binary_data
* FIELDNAMES =
EXCEPTIONS
file_write_error = 1
no_batch = 2
gui_refuse_filetransfer = 3
invalid_type = 4
no_authority = 5
unknown_error = 6
header_not_allowed = 7
separator_not_allowed = 8
filesize_not_allowed = 9
header_too_long = 10
dp_error_create = 11
dp_error_send = 12
dp_error_write = 13
unknown_dp_error = 14
access_denied = 15
dp_out_of_memory = 16
disk_full = 17
dp_timeout = 18
file_not_found = 19
dataprovider_exception = 20
control_flush_error = 21
OTHERS = 22
it_receivers-receiver = 'gmailid'.
it_receivers-rec_type = 'U'.
it_receivers-com_type = 'INT'.
APPEND it_receivers .
it_message-line = 'Test for sending email'.
APPEND it_message.
CALL FUNCTION 'ZSEND_MAIL_ATTACHMENT'
EXPORTING
v_file_path = 'C:\Test\Testing.pdf'
v_subject = 'Test Mail'
TABLES
it_receivers = it_receivers[]
it_message = it_message[].
IF sy-subrc EQ 0.
COMMIT WORK.
* Push mail out from SAP outbox
SUBMIT rsconn01 WITH mode = 'INT' AND RETURN.
ENDIF. -
Sending external email from SAP with following requirements...
Hi All,
I need to send external emails from SAP by meeting following requirements.
1) With subject line more than 100 characters.
2) No attachments, only body which has specific format (blueprint/layout) and would be amended often, hence code shouldn't be touched during amendments.
3) Should be able to know the success/failure of mail sending at program level.Hi,
The code below demonstrates how to send an email to an external email address
*& Report ZSENDEMAIL *
*& Example of sending external email via SAPCONNECT *
REPORT zsendemail .
PARAMETERS: psubject(40) type c default 'Hello',
p_email(40) type c default '[email protected]' .
data: it_packing_list like sopcklsti1 occurs 0 with header line,
it_contents like solisti1 occurs 0 with header line,
it_receivers like somlreci1 occurs 0 with header line,
it_attachment like solisti1 occurs 0 with header line,
gd_cnt type i,
gd_sent_all(1) type c,
gd_doc_data like sodocchgi1,
gd_error type sy-subrc.
data: it_message type standard table of SOLISTI1 initial size 0
with header line.
*START-OF-SELECTION.
START-OF-SELECTION.
Perform populate_message_table.
*Send email message, although is not sent from SAP until mail send
*program has been executed(rsconn01)
PERFORM send_email_message.
*Instructs mail send program for SAPCONNECT to send email(rsconn01)
perform initiate_mail_execute_program.
*& Form POPULATE_MESSAGE_TABLE
Adds text to email text table
form populate_message_table.
Append 'Email line 1' to it_message.
Append 'Email line 2' to it_message.
Append 'Email line 3' to it_message.
Append 'Email line 4' to it_message.
endform. " POPULATE_MESSAGE_TABLE
*& Form SEND_EMAIL_MESSAGE
Send email message
form send_email_message.
Fill the document data.
gd_doc_data-doc_size = 1.
Populate the subject/generic message attributes
gd_doc_data-obj_langu = sy-langu.
gd_doc_data-obj_name = 'SAPRPT'.
gd_doc_data-obj_descr = psubject.
gd_doc_data-sensitivty = 'F'.
Describe the body of the message
clear it_packing_list.
refresh it_packing_list.
it_packing_list-transf_bin = space.
it_packing_list-head_start = 1.
it_packing_list-head_num = 0.
it_packing_list-body_start = 1.
describe table it_message lines it_packing_list-body_num.
it_packing_list-doc_type = 'RAW'.
append it_packing_list.
Add the recipients email address
clear it_receivers.
refresh it_receivers.
it_receivers-receiver = p_email.
it_receivers-rec_type = 'U'.
it_receivers-com_type = 'INT'.
it_receivers-notif_del = 'X'.
it_receivers-notif_ndel = 'X'.
append it_receivers.
Call the FM to post the message to SAPMAIL
call function 'SO_NEW_DOCUMENT_ATT_SEND_API1'
exporting
document_data = gd_doc_data
put_in_outbox = 'X'
importing
sent_to_all = gd_sent_all
tables
packing_list = it_packing_list
contents_txt = it_message
receivers = it_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.
Store function module return code
gd_error = sy-subrc.
Get it_receivers return code
loop at it_receivers.
endloop.
endform. " SEND_EMAIL_MESSAGE
*& Form INITIATE_MAIL_EXECUTE_PROGRAM
Instructs mail send program for SAPCONNECT to send email.
form initiate_mail_execute_program.
wait up to 2 seconds.
if gd_error eq 0.
submit rsconn01 with mode = 'INT'
with output = 'X'
and return.
endif.
endform. " INITIATE_MAIL_EXECUTE_PROGRAM
Hope this helps.
Reward if helpful.
Regards,
Sipra -
FM to SEND an email to SAP USER
Hi Gurus,
Pls let me know the FM if any to send a email to SAP USER (eg. DANYGG) so that it will go to SAP INBOX of the user in T.code So01.
Promise to reward.
Regards
Machi,
check with this code, and reward if u find useful..
Table Declarations
TABLES: SOLI.
Data Declarations
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
PARAMETERS: SAPID RADIOBUTTON GROUP ADDR,
EMAIL_ID RADIOBUTTON GROUP ADDR.
SELECTION-SCREEN END OF BLOCK B1.
SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-002.
SELECT-OPTIONS: ID FOR SOLI-LINE NO INTERVALS.
SELECT-OPTIONS: CC FOR SOLI-LINE NO INTERVALS.
SELECT-OPTIONS: BCC FOR SOLI-LINE NO INTERVALS.
*PARAMETERS: SENDER LIKE SOUD-USRNAM.
SELECTION-SCREEN END OF BLOCK B2.
SELECTION-SCREEN BEGIN OF BLOCK B3 WITH FRAME TITLE TEXT-009.
PARAMETERS: SUB_LINE(60) TYPE C.
SELECTION-SCREEN END OF BLOCK B3.
SELECTION-SCREEN BEGIN OF BLOCK B4 WITH FRAME TITLE TEXT-008.
SELECT-OPTIONS: TEXT1 FOR SOLI-LINE NO INTERVALS.
SELECTION-SCREEN END OF BLOCK B4.
SELECTION-SCREEN BEGIN OF BLOCK B5 WITH FRAME TITLE TEXT-009.
SELECTION-SCREEN BEGIN OF LINE.
parameters: P_ATTACH as checkbox.
selection-screen comment 3(30) text-010.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK B5.
DATA: MAIL_CONTENT LIKE SOLI OCCURS 0 WITH HEADER LINE,
SUBJECT_LINE LIKE SOOD1-OBJDES.
Start of program processing
START-OF-SELECTION.
Get the Body of the Message from the selection screen or from
calling program
LOOP AT TEXT1.
MOVE TEXT1-LOW TO MAIL_CONTENT-LINE.
APPEND MAIL_CONTENT.
ENDLOOP.
Subject of the Message
MOVE SUB_LINE TO SUBJECT_LINE.
call a routine to send the workflow message
PERFORM SEND_EMAIL
TABLES MAIL_CONTENT
USING SUBJECT_LINE.
*& Form SEND_EMAIL
Send Workflow message
FORM SEND_EMAIL TABLES OBJCONT STRUCTURE MAIL_CONTENT
USING TITLE LIKE SOOD-OBJDES.
DATA: RECEIVERS LIKE SOOS1 OCCURS 0 WITH HEADER LINE,
TSOOD1 LIKE SOOD1,
PACKING_LIST LIKE SOXPL OCCURS 0 WITH HEADER LINE,
OBJCONT1 LIKE MAIL_CONTENT OCCURS 0 WITH HEADER LINE.
DATA: BEGIN OF AT_HEADER OCCURS 1.
INCLUDE STRUCTURE SOLI.
DATA: END OF AT_HEADER.
CLEAR: TSOOD1,
RECEIVERS.
REFRESH RECEIVERS.
MOVE: SY-LANGU TO TSOOD1-OBJLA,
'Email Notice' TO TSOOD1-OBJNAM,
'C' TO TSOOD1-OBJSNS,
TITLE TO TSOOD1-OBJDES.
'SCHIAVONIR' TO TSOOD1-OWNNAM.
loop through each ID and move them to recipient table
LOOP AT ID.
TRANSLATE ID-LOW TO UPPER CASE.
IF SAPID = 'X'.
MOVE: SY-DATUM TO RECEIVERS-RCDAT,
SY-UZEIT TO RECEIVERS-RCTIM,
' ' TO RECEIVERS-RECESC,
ID-LOW TO RECEIVERS-RECNAM,
'X' TO RECEIVERS-SNDEX.
ELSE.
MOVE: SY-DATUM TO RECEIVERS-RCDAT,
SY-UZEIT TO RECEIVERS-RCTIM,
'U' TO RECEIVERS-RECESC,
'U-' TO RECEIVERS-RECNAM,
ID-LOW TO RECEIVERS-RECEXTNAM.
ENDIF.
APPEND RECEIVERS.
CLEAR RECEIVERS.
ENDLOOP.
loop through each CC and move them to recipient table
LOOP AT CC.
TRANSLATE CC-LOW TO UPPER CASE.
IF SAPID = 'X'.
MOVE: SY-DATUM TO RECEIVERS-RCDAT,
SY-UZEIT TO RECEIVERS-RCTIM,
' ' TO RECEIVERS-RECESC,
CC-LOW TO RECEIVERS-RECNAM,
'X' TO RECEIVERS-SNDEX,
'X' TO RECEIVERS-SNDCP.
ELSE.
MOVE: SY-DATUM TO RECEIVERS-RCDAT,
SY-UZEIT TO RECEIVERS-RCTIM,
'U' TO RECEIVERS-RECESC,
'U-' TO RECEIVERS-RECNAM,
CC-LOW TO RECEIVERS-RECEXTNAM,
'X' TO RECEIVERS-SNDCP.
ENDIF.
APPEND RECEIVERS.
CLEAR RECEIVERS.
ENDLOOP.
loop through each BCC and move them to recipient table
LOOP AT BCC.
TRANSLATE BCC-LOW TO UPPER CASE.
IF SAPID = 'X'.
MOVE: SY-DATUM TO RECEIVERS-RCDAT,
SY-UZEIT TO RECEIVERS-RCTIM,
' ' TO RECEIVERS-RECESC,
BCC-LOW TO RECEIVERS-RECNAM,
'X' TO RECEIVERS-SNDEX,
'X' TO RECEIVERS-SNDBC.
ELSE.
MOVE: SY-DATUM TO RECEIVERS-RCDAT,
SY-UZEIT TO RECEIVERS-RCTIM,
'U' TO RECEIVERS-RECESC,
'U-' TO RECEIVERS-RECNAM,
BCC-LOW TO RECEIVERS-RECEXTNAM,
'X' TO RECEIVERS-SNDBC.
ENDIF.
APPEND RECEIVERS.
CLEAR RECEIVERS.
ENDLOOP.
AT_HEADER = SY-DATUM.
APPEND AT_HEADER.
AT_HEADER = SY-UZEIT.
APPEND AT_HEADER.
IF SENDER EQ SPACE.
SENDER = SY-UNAME.
ENDIF.
IF P_ATTACH EQ 'X'.
PACKING_LIST-HEAD_START = 1.
PACKING_LIST-HEAD_NUM = 2.
PACKING_LIST-BODY_START = 1.
PACKING_LIST-BODY_NUM = 9999.
PACKING_LIST-FILE_EXT = 'TXT'.
APPEND PACKING_LIST.
CLEAR PACKING_LIST.
APPEND LINES OF OBJCONT TO OBJCONT1.
REFRESH OBJCONT.
ENDIF.
CALL FUNCTION 'SO_OBJECT_SEND'
EXPORTING
OBJECT_HD_CHANGE = TSOOD1
OBJECT_TYPE = 'RAW'
TABLES
OBJCONT = OBJCONT
RECEIVERS = RECEIVERS
ATT_HEAD = AT_HEADER
ATT_CONT = OBJCONT1
PACKING_LIST = PACKING_LIST
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.
ENDFORM. " SEND_EMAIL
regards
dinesh -
Changing sender on sent email via SAP
I need to change the sender on sent email via sap; i mean, no sy-uname, something like [email protected]
RegardsCheck the sample code
*& Report ZASD
REPORT ZASD.
This example shows how to send
- a simple text provided in an internal table of text lines
- and an attached MS word document provided in internal table
- to some internet email address.
All activities done via facade CL_BCS!
DATA: send_request TYPE REF TO cl_bcs.
DATA: text TYPE bcsy_text.
data: binary_content type solix_tab.
DATA: document TYPE REF TO cl_document_bcs.
DATA: sender TYPE REF TO cl_sapuser_bcs.
DATA: recipient TYPE REF TO if_recipient_bcs.
DATA: bcs_exception type ref to cx_bcs.
data: sent_to_all type os_boolean.
START-OF-SELECTION.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
filename = 'c:\wagonTrain.gif'
FILETYPE = 'BIN'
HAS_FIELD_SEPARATOR = ' '
HEADER_LENGTH = 0
READ_BY_LINE = 'X'
DAT_MODE = ' '
CODEPAGE = ' '
IGNORE_CERR = ABAP_TRUE
REPLACEMENT = '#'
CHECK_BOM = ' '
VIRUS_SCAN_PROFILE = VIRUS_SCAN_PROFILE
IMPORTING
FILELENGTH = FILELENGTH
HEADER = HEADER
TABLES
data_tab = binary_content
EXCEPTIONS
FILE_OPEN_ERROR = 1
FILE_READ_ERROR = 2
NO_BATCH = 3
GUI_REFUSE_FILETRANSFER = 4
INVALID_TYPE = 5
NO_AUTHORITY = 6
UNKNOWN_ERROR = 7
BAD_DATA_FORMAT = 8
HEADER_NOT_ALLOWED = 9
SEPARATOR_NOT_ALLOWED = 10
HEADER_TOO_LONG = 11
UNKNOWN_DP_ERROR = 12
ACCESS_DENIED = 13
DP_OUT_OF_MEMORY = 14
DISK_FULL = 15
DP_TIMEOUT = 16
OTHERS = 17
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
PERFORM main.
FORM main *
FORM main.
try.
-------- create persistent send request ------------------------
send_request = cl_bcs=>create_persistent( ).
-------- create and set document with attachment ---------------
create document from internal table with text
APPEND 'Hello world!' TO text.
document = cl_document_bcs=>create_document(
i_type = 'RAW'
i_text = text
i_length = '12'
i_subject = 'test created by BCS_EXAMPLE_2' ).
add attachment to document
BCS expects document content here e.g. from document upload
binary_content = ...
CALL METHOD document->add_attachment
EXPORTING i_attachment_type = 'GIF'
i_attachment_subject = 'My attachment'
i_att_content_hex = binary_content.
add document to send request
CALL METHOD send_request->set_document( document ).
<b>* -
set sender -
note: this is necessary only if you want to set the sender
different from actual user (SY-UNAME). Otherwise sender is
set automatically with actual user.
sender = cl_sapuser_bcs=>create( sy-uname ).
CALL METHOD send_request->set_sender
EXPORTING i_sender = sender.</b>
--------- add recipient (e-mail address) -----------------------
create recipient - please replace e-mail address !!!
recipient = cl_cam_address_bcs=>create_internet_address(
'YOUR [email protected]' ).
add recipient with its respective attributes to send request
CALL METHOD send_request->add_recipient
EXPORTING
i_recipient = recipient
i_express = 'X'.
CALL METHOD send_request->set_send_immediately( 'X' ).
---------- send document ---------------------------------------
CALL METHOD send_request->send(
exporting
i_with_error_screen = 'X'
receiving
result = sent_to_all ).
if sent_to_all = 'X'.
write text-003.
endif.
COMMIT WORK.
* exception handling
* replace this very rudimentary exception handling
* with your own one !!!
catch cx_bcs into bcs_exception.
write: 'Fehler aufgetreten.'(001).
write: 'Fehlertyp:'(002), bcs_exception->error_type.
exit.
endtry.
ENDFORM.
*Check the BOL Part
Message was edited by: Amandeep Singh -
Cannot Send Email from SAP Business One
Hi Experts
I have configured SAP Email Services from the Mailer Service and Customer can send emails all the while,
Now I have an Issue for One User,
Iam using the Same Machine, Same Database with Manager Login, I can send Email from SAP with Attachments
But When I use another Super user the system is not delivering the Email and it Goes to the Sent box (but not delivered)
Have anyone encountered the Issue before
Please hep to solve this issue permanently
Thanks and Regards
Vinodh Kumar MohanHi Vinodh Kumar Mohan,
If the email can be found in Sent box, it must be delivered already.
The problem could be on the email recipient side. It may go to the junk mail.
Thanks,
Gordon -
hiii
<b>Is it possible to send mail from SAP to External user??????if possible does BASIS people had to do something???</b>
I want to send the email from sap to external user([email protected]).My mail will consist of some changes made in production order(CO03). for which i had created the BADI. That part is over now i want to send the mail.
<b>I got many sample programs in sdn but when i enter the email address it execute but mail is not sent.....I want to know by just executing Zprogram mail will be sent or there is some role for BASIS also..............</b>
Thanking you.
Regards.There is a transaction called SCOT that needs to be configured
http://www.sap-basis-abap.com/sapbs035.htm
http://www.sap-img.com/basis/basis-faq.htm
http://help.sap.com/saphelp_nw2004s/helpdata/en/2b/d925bf4b8a11d1894c0000e8323c4f/frameset.htm -
Send email from SAP using SMTP-AUTH
Dear all,
I would like to send email from SAP to external SMTP server using authenticated method.
Can I set up this scenario with SAPConnect?
Or are there any other methods to set up this scenario?
Thanks, Regards,
FendhyHi,
You dont need anu authentication to be set :
Just follow below steps :
Simple steps to do the SMTP configuration :
1. Use transaction SCOT
3. Double Click on SMTP
4. You will get a window and fill in description
5. Tick the "Node in use" box
6. Enter the hostname of the email exchange server
7. Mail port will be 25
8. Click on the button next to Internet called "Set"
9. You will get another window, in the "address area" box, enter *
10. Click the green check button to exit the second window
11. Click the green check button to exit the main window
12. From top menu: Settings -> Default Domain
13. in the small box that appears enter the domain name which is the last part after the @ sign. The domain name would be company.com
14. You need to define a job to process the email, from top menu: View -> Jobs
15. From top menu: Job -> Create
16. Enter a name
17. Click on "INT" in the list then "Schedule job" button
18. Enter start date and time, then click on "Schedule Periodically" button
19. Enter something like every 10 minutes.
20. the configuration is now complete. To test it, you need to have an email defined in your user id properties. Use SU01 for that.
21. Use transaction SO00
22. Put Title, and text in the body, then enter your email address below, the recepient type would be "internet address"
23. After a maximum of 10 minutes you should get the email address.
Regards,
Nirmal.K -
OIM - SAP Employee Recon and SAP User Management Connectors vs. OC4J
In reading through the SAP connector documentation I've found that we cannot use OC4J to run OIM if the 9.0.3 SAP User Management Connector or SAP Employee Recon Connector is used. This is all related to a conflict in JDK versions supported between the SAP JCo (Java Connector) library and OC4J. A thought we've had is to use a Remote Manager for these connectors. Can anyone validate this approach? Is it possible to use a different JDK version with your remote manager? Is there another workaround that anyone is aware of?
ThanksHi,
The remote manager should work with different JDKs. We are going to be doing the same thing for one of our adapters.
As for SAP, I cannot think of another workaround -- we actually abandoned the SAP JCo approach and are doing web services with XI.
Thanks,
Deborah
http://www.linkedin.com/in/dvolk -
Export file from SAP can not open into seperate rows in excel
Dear all,
When I export data from SAP to .XLS file (With Unicode) and open with MS Excel.
The data in file show with single line and it is not seperate as rows in excel.
How can I solve this issue? It is occure this error in some laptop.
Regards,
PanneeThe data in file show with single line and it is not seperate as rows in excel.
Do you mean you are not able to see multiple columns? If that is the case use text to column from excel's data menu and give a try. -
Korean text displayed as junk char in xls attachmnt sent thru email frm SAP
Hi All,
I am sending a report output to users as an xls attachment through email from SAP.
I am facing problem with languages other than English. For ex a customer name is in korean lang and when I display the name in ALV it is fine also when I download from ALV it is fine only problem when I send that report through email.
Excel is having all junk char instead of Korean text.
I am using function modules SCMS_STRING_TO_XSTRING,SCMS_XSTRING_TO_BINARY and SO_NEW_DOCUMENT_ATT_SEND_API1 to send email.
I am using above FM because the data is more than 255 char.
Please help me to send other lang texts in XLS attachment through email.
Regards,
Suresh.Hi All,
I am sending a report output to users as an xls attachment through email from SAP.
I am facing problem with languages other than English. For ex a customer name is in korean lang and when I display the name in ALV it is fine also when I download from ALV it is fine only problem when I send that report through email.
Excel is having all junk char instead of Korean text.
I am using function modules SCMS_STRING_TO_XSTRING,SCMS_XSTRING_TO_BINARY and SO_NEW_DOCUMENT_ATT_SEND_API1 to send email.
I am using above FM because the data is more than 255 char.
Please help me to send other lang texts in XLS attachment through email.
Regards,
Suresh. -
Automatic outbound email on sap
Dear All,
what is procedure to configuring automatic outbound email on sap.
Regards,
RajuHI,
I will send email thorugh our mail server by using sap . i have configured scot setting but some error occured that is way i am asking procedure -
Configuring Outgoing Email in SAP Basis Services
Hi gurus
Can any body tell me the step by step procedure for how to configure outgoing Email in SAP basis services
Thanks and regards
S.Satyanarayana RajuHi Satya,
U can configure out going mails from your SAP system by using SMTP.
have a look on the below link.. u can get complete picture of the mail configuration.
http://help.sap.com/saphelp_nw04s/helpdata/EN/af/73563c1e734f0fe10000000a114084/content.htm
they have explained every thing clearly there and also have a look on the below note.
SAP Note 1205132 - Configure SMTP Destination to use multiple email servers
Cheers and have fun.
-Srini -
Classes and methods to send email to SAP inbox
Hi,
I want an appropriate class and method to send emails to SAP Inbox.
My objective is that i convert spool to PDF and send it to SAP inbox as an attachment.
I've used 'CONVERT_ABAPSPOOLJOB_2_PDF' and 'SX_TABLE_LINE_WIDTH_CHANGE' to generate PDF attachment.
I tried Function modules 'SO_DOCUMENT_SEND_API1'/'SO_NEW_DOCUMENT_ATT_SEND_API1' to send email.
It was working fine till now (for last 4 months). Now the Basis team has run some patches due to which the PDFs are getting damaged.
Now the FMs 'SO_DOCUMENT_SEND_API1'/'SO_NEW_DOCUMENT_ATT_SEND_API1' seems to be useless.
So i tried some methods in classes cl_document_bcs and cl_bcs. These are working fine for Internet mails but not SAP mails.
Please suggest me some Classes and methods to send the PDF atachments to SAP inbox.to have all SAP inbox messages into lotus notes inbox you have to sync the same with the use of connectors rather than resending them
check out this link
http://www-128.ibm.com/developerworks/lotus/library/lei-sap/
for outlook its done using MAPI
http://www.sapgenie.com/faq/exchange.htm
Regards
Raja -
Is there any way to import/export email from a user's account?
What do you want to import/export from?
I think you can do a dump of someone's mailbox using the imsbackup utility, but am not sure what format this gives you. Probably you can only import this into another iMS server.
Apart from that, you could look at what tools your mail clients have for saving and importing messages. I think Outlook express has an archive utility that you could use. To import from Outlook to the server, you could use the iPlanet sync tool. This will synchronise in both directions between the iMS mail server and various clients. These include Outlook, Windows CE handhelds, palms, etc. Basically, if you set this up to synchronise with Outlook, then you can import/export using anything that will interface with Outlook.
Of course you don't have to use Microshaft products. You could use any mail client to do this. Not sure about synching with other clients cos we've not done it.
I'm not sure how you can get hold of this synching tool. There were various beta versions floating around about a year or so ago and I would have expected that they would have released a supported version by now. Then again.....
Maybe you are looking for
-
Downloads resume from zero, not where they left off
I know this is a tired question, but it STILL HAS NOT BEEN ADDRESSED BY APPLE. Why do interrupted downloads start back at zero instead of picking up where they left off? Is this too difficult of a bug for the iTunes engineers to deal with? Being over
-
Trying to set up my iPad for mail and despite my clearly writing my outgoing server as AAPT it changes itself to big pond by default and so I can't send or receive . How do iI get the system to accept AAPT as my outgoing server? Help please Jackfromq
-
TS4268 How can I remove an imessage phone number?
How can I remove a mobile phone number from Settings>Messages>Send & Receive?
-
dear i am creaintg a report, in which i am using two parameters, one parameter is from the DB while other paramter is dependant upon user input like YES or NO. I have two queries, if user enters YES then Q_1 should be executed if user enters NO then
-
Hi all, Following is the clients requirements for RG1 report, 1. When there is opening qnty for materials,but no transactions(production or issues) the report should show the details of opening & closing stock of FG stocks, where as the above require