Diese Seite mit anderen teilen ...

Informationen zum Thema:
Forum:
WX-Products: Reports of malfunctions & bugs
Beiträge im Thema:
3
Erster Beitrag:
vor 6 Jahren, 2 Monaten
Letzter Beitrag:
vor 4 Jahren, 9 Monaten
Beteiligte Autoren:
Allard, Jose Antonio Garrido, Tom Gyssels

Error when sending mail using variable

Startbeitrag von Tom Gyssels am 31.01.2012 14:42

Whenever I try to send an email using an email variable, I get the error "unable to send message without specifying sender".
This problem does not occur when using the email structure, but I need the variable because I need to pass it further around.
This is my current code, in which I clearly specify the sender.

PROCEDURE loc_SendMail()
LOCAL
recipients is array of string
MyEmail is Email

IF NOT EmailStartSMTPSession("HelpdeskSend","","relay.skynet.be") THEN
RESULT Null
END
EDT_Recipient=Replace(EDT_Recipient,";",",")
StringToArray(EDT_Recipient,recipients,",")
FOR EACH sRecip OF recipients
ArrayAdd(MyEmail.Recipient,sRecip)
END
MyEmail.Subject=EDT_Subject
MyEmail.HTML=EDT_Content
FOR EACH ROW OF LOOP_Attachments
EmailLoadAttachment(MyEmail,LOOP_Attachments.ATT_AttPath)
Debug("Added mail attachment: "+LOOP_Attachments.ATT_AttPath)
END
MyEmail..Sender="Helpdesk "
MyEmail..SenderAddress="helpdesk@domain.com"
IF ArrayCount(MyEmail.Recipient)>0 THEN
IF NOT EmailSendMessage("HelpdeskSend",MyEmail,True) THEN
Debug(""+"Mail kon niet verzonden worden"+ErrorInfo(errFullDetails))
ELSE
Debug(""+"Mail met succes verzonden")
END
END
EmailCloseSession("ReportSend")
RESULT MyEmail

Antworten:

Hi.

Didn't try in WD 16, but in WD 17 IT WORKS:
-using SMTP or Outlook session
-usuing email variable or email structure.

What it doesnt work is to read messageID from outlook emails, or to set messageID and send the email throught outlook.
I wrote PCSOFT about that problem three months ago, and i think it is very important to identify the emails you send or recive in outlook.

von Jose Antonio Garrido - am 25.08.2012 00:02
In webdev 18 sending mails is ok ( php modus ). I used a procedure in the code of the mail sending , then, Faults appeard. I removed the procudure and added all code in one section and it worked like a charm??

regards

Allard

von Allard - am 30.06.2013 21:34
Zur Information:
MySnip.de hat keinen Einfluss auf die Inhalte der Beiträge. Bitte kontaktieren Sie den Administrator des Forums bei Problemen oder Löschforderungen über die Kontaktseite.
Falls die Kontaktaufnahme mit dem Administrator des Forums fehlschlägt, kontaktieren Sie uns bitte über die in unserem Impressum angegebenen Daten.