| Home | All functions | Legacy functions | Categories |
Send a temporary SMTP test message and include both outgoing and incoming setup details in the generated message body.
Prototype: vuAutoDetectSendTestMessageEx(LONG InOutBufLen, *CSTRING InFromEmail, *CSTRING InToEmail, *CSTRING InSubjectPrefix, LONG InConfigOrigin, *CSTRING InSmtpHost, LONG InSmtpPort, LONG InSmtpSecurityMode, LONG InSmtpAuthMode, *CSTRING InSmtpUser, *CSTRING InPassword, LONG InProviderId, *CSTRING InOAuthAccountKey, *CSTRING InPopHost, LONG InPopPort, LONG InPopSecurityMode, LONG InPopAuthMode, *CSTRING InPopUser, *CSTRING InImapHost, LONG InImapPort, LONG InImapSecurityMode, LONG InImapAuthMode, *CSTRING InImapUser, *CSTRING OutSmtpResponseCode, *CSTRING OutSmtpResponseText), SIGNED, PROC, PASCAL, RAW, NAME(‘vuAutoDetectSendTestMessageEx’)
Setup/test-send messages honor the same legacy save-folder and sent-mail log settings as normal sends. If vuSetSaveFolder() or vuGlobalsSetEmailFolder() has set a valid folder before the test send, vuMailKit saves the outgoing test message as an .eml file before the SMTP send attempt. If vuSetMailLog() or vuLogSetFile() has selected a sent-mail CSV log, the test-send attempt is logged. Successful sends include the saved path when an outgoing copy was saved. Failed sends are logged with the result text.
rc LONG
fromAdr CSTRING(256)
toAdr CSTRING(256)
subject CSTRING(128)
smtpHost CSTRING(256)
smtpUser CSTRING(256)
password CSTRING(256)
code CSTRING(64)
text CSTRING(512)
fromAdr = 'sender@example.com'
toAdr = 'recipient@example.com'
subject = 'vuMailKit setup test'
smtpHost = 'smtp.example.com'
smtpUser = 'sender@example.com'
password = 'app-password-or-smtp-password'
code = ''
text = ''
rc = vuAutoDetectSendTestMessageEx(SIZE(text), fromAdr, toAdr, subject, |
0, smtpHost, 587, 2, 0, smtpUser, password, 0, '', |
'', 0, 0, 0, '', '', 0, 0, 0, '', code, text)
MESSAGE('Send test rc=' & rc & '|Response=' & CLIP(text))
| Home | All functions | Legacy functions | Categories |