NetTalk Central

Author Topic: Email require authentication  (Read 2759 times)

johanco123

  • Full Member
  • ***
  • Posts: 245
    • View Profile
    • Email
Email require authentication
« on: November 21, 2012, 09:07:37 PM »
Hi Bruce

I try to send emails from my web browser application with a button to send emails. If the mail server requires SMTP authentication to send the emails, how do I specify the User name and Password for the authentication.

If there is no authentication required, then the sending of the mail works perfectly.

this is the code that I uses

 EmailServer      = 'xxx.xxx.xxx.xx'
 EmailPort        = 465
 ThisSendEmail.AuthUser = 'username'
 ThisSendEmail.AuthPassword = 'password'

 EmailTo          = parms.pEmailTo
  if parms.pEmailFrom = ''
    emailFrom = 'alert@xxxxxx.co.za'
  Else
    EmailFrom        = parms.pEmailFrom
  End

 EmailCC          = parms.pEmailCC
 EmailBCC         = parms.pEmailBCC
 EmailSubject     = parms.pEmailSubject
 EmailFileList    = parms.pEmailFileList
 EmailMessageText = parms.pEmailMessageText
 EmailMessageHtml = parms.pEmailMessageHtml

Tanks
Johan

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Email require authentication
« Reply #1 on: November 21, 2012, 09:15:31 PM »
Hi Johan,

I'm not sure what you're asking, because you have the properties set in your example code there;

 ThisSendEmail.AuthUser = 'username'
 ThisSendEmail.AuthPassword = 'password'

Obviously you need to set these to appropriate values, but these are the "SMTP Authentication" part.

cheers
Bruce