2013 Oct 23 2:45 PM
Hi All,
We are sending email from E-rec to the external email address. In SOST it is coming up with the correct email address (lets say [email protected]), this we always want as the sender. We have created the enhancement in FM "SX_GET_SMTP_SENDER_ADDRESS" perform get_sender_address. Here we pick up the sender from a z table and determine the sender email address regardless of who is the actual originator. However in the SMTP log it is showing the sender as who has manually start sending process from SOST and not [email protected]. On further analysis I found that :
1. When I send the test email from tcode SBWP, In FM "SO_OBJECT_MIME_GET" it call perform get_smtp_envelope_sender.
2. In above perform at line 30, it tries to get object reference of class cl_cam_address_bcs and it gets initial. Hence it goes ahead and call FM "
SX_GET_SMTP_SENDER_ADDRESS" in the else part and execute our enhancement which we have written to get the sender address.
3. While if we process the email from SOST it does everything same above except it gets the reference of class cl_cam_address_bcs and does not go to else part. Instead it assigns the Sender Address as the user who is executing SOST work item.
this result in fail of email sending. Its happening in recent time in our system. Please suggest a way.
< Urgency Removed >>, please help.
Thanks & Regards,
Arvind Patel
Message was edited by: Kesavadas Thekkillath
Hi All,
We are sending email from E-rec to the external email address. In SOST it is coming up with the correct email address (lets say [email protected]), this we always want as the sender. We have created the enhancement in FM "SX_GET_SMTP_SENDER_ADDRESS" perform get_sender_address. Here we pick up the sender from a z table and determine the sender email address regardless of who is the actual originator. However in the SMTP log it is showing the sender as who has manually start sending process from SOST and not [email protected]. On further analysis I found that :
1. When I send the test email from tcode SBWP, In FM "SO_OBJECT_MIME_GET" it call perform get_smtp_envelope_sender.
2. In above perform at line 30, it tries to get object reference of class cl_cam_address_bcs and it gets initial. Hence it goes ahead and call FM "
SX_GET_SMTP_SENDER_ADDRESS" in the else part and execute our enhancement which we have written to get the sender address.
3. While if we process the email from SOST it does everything same above except it gets the reference of class cl_cam_address_bcs and does not go to else part. Instead it assigns the Sender Address as the user who is executing SOST work item.
this result in fail of email sending. Its happening in recent time in our system. Please suggest a way.
< Urgency Removed >>, please help.
Thanks & Regards,
Arvind Patel
Message was edited by: Kesavadas Thekkillath
2013 Oct 23 2:48 PM
Hi Arvind,
that looks like a SAP bug, did you open a message ? (specially for part 3)
regards
Fred
2013 Oct 24 6:56 AM
Hi Fred,
Thank you very much for your reply.
Yeah we had opened a message and they asked for the trace. they said the trace is correct, further they had a point that if the issue is with SAP standard FM/Method, it should fail for every email however this might not be the correct point based on different condition.
I will again send them the further analysis which I have described here. Any other suggestion please.
Thanks & Regards,
Arvind Patel
2013 Oct 23 3:48 PM
Arvind,
Could I see a snippet of your code that is failing. It might help me better understand your problem and help more.
Neal
2013 Oct 24 7:02 AM
hi Neal,
This I have described above in my post that, while sending email from Erec, lo_cam is not coming initial and hence initializing the lv_sender with the person who is processing the send from SOST. If it would have been initial, it will go to the below highlighted if part and will execute our user exit to fetch the sender from Z table.
Please help.
Thanks & Regards,
Arvind Patel
2013 Oct 23 3:49 PM
Can you use the cl_sapuser_bcs=>create method to force the correct user ID for the sender OR use the I_ADDRESS_NAME parameter for the cl_cam_address_bcs=>create_internet_address. The description says 'obsolete' for the parameter but it's in use in versions later than 7.0.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |