07-09-2007 3:42 PM
Hi,
my report should send an email to a user. Everything is fine, the email was send to the user but doesn´t arrive. Could you please tell me what could be wrong?
Greetz Dominik
07-09-2007 3:43 PM
07-09-2007 3:43 PM
Are you sending the mail to SBWP? Outlook? External Mail? You should check transaction <b>SCOT</b>...Or post your code -:)
Greetings,
Blag.
07-09-2007 3:43 PM
07-09-2007 3:47 PM
07-09-2007 3:49 PM
Check this code....I used to send mails to a customers...
DATA: APPOUTLOOK TYPE OLE2_OBJECT.
DATA: APPOUT2 TYPE OLE2_OBJECT.
DATA: APPITEM TYPE OLE2_OBJECT.
DATA: NAMESPACE TYPE OLE2_OBJECT.
DATA: BODY(5000) TYPE C.
DATA: CR TYPE X VALUE 13.
DATA: W_MAIL(5000) TYPE C.
CALL FUNCTION 'ZFGETCONST'
EXPORTING
P_PROGRAM = 'ZSDR0007N'
P_CAMPO = 'MAIL'
TABLES
TI_CONST = IT_MAILS.
LOOP AT IT_MAILS WHERE LOW = SY-SLSET.
CONCATENATE W_MAIL IT_MAILS-HIGH ';'
INTO W_MAIL.
ENDLOOP.
LOOP AT TI_LOG ASSIGNING <LOG>.
PERFORM QUITAR_CEROS CHANGING <LOG>-MATNR.
CONCATENATE BODY <LOG>-VKORG <LOG>-VKBUR <LOG>-MATNR
<LOG>-KUNNR <LOG>-EAN11 <LOG>-MENSA CR INTO BODY
SEPARATED BY SPACE.
ENDLOOP.
CREATE OBJECT APPOUTLOOK 'outlook.application' .
CALL METHOD OF APPOUTLOOK 'GetNameSpace' = NAMESPACE
EXPORTING #1 = 'MAPI'.
CALL METHOD OF APPOUTLOOK 'CreateItem' = APPITEM
EXPORTING #1 = '0'.
SET PROPERTY OF APPITEM 'To' = W_MAIL.
SET PROPERTY OF APPITEM 'Subject' = 'Log de Errores CONCESIONARIOS'.
SET PROPERTY OF APPITEM 'Body' = BODY.
CALL METHOD OF APPITEM 'Send'.
FREE OBJECT APPITEM.
FREE OBJECT NAMESPACE.
FREE OBJECT APPOUTLOOK.
Maybe you are missing something....
Greetings,
Blag.
07-09-2007 4:08 PM
I can see that the email sent to the receiver in the transaction SOST. Status: "sent"!
07-09-2007 4:18 PM
That's weird....Maybe some filter policies on Outlook...Are you sending the mail to yourself? Try that....
Greetings,
Blag.
07-09-2007 4:33 PM
Hi,
Check ths if this is of any help to you.
https://www.sdn.sap.com/irj/sdn/wiki?path=/display/snippets/email%2bfrom%2bsap
Thanks.
07-10-2007 9:32 AM
i`ve sent the email(s) to my account as well as to other accounts, but they still haven´t arrived yet.
07-10-2007 9:39 AM
07-10-2007 9:40 AM
07-10-2007 9:48 AM
Have you created and address area ( scott --> Goto --> Address area) ?
if this may be useful reawards pint are appreciated.
07-10-2007 10:01 AM
07-10-2007 10:12 AM
if you already created an address area correctly , you don't need to create a second of course.
If the test route from scot and the status is sent it might be a network problem related your smtp server.