Sending e-mails from my hosted application.

Discussion in 'ASP.NET / ASP.NET Core' started by dsouza, Dec 13, 2005.

Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.
  1. I have an application that requires to send notifications by email, I am trying to send them using the


    Framework library Web.Mail, but I do not know how to send credentials or the correct way to implement it.








    Public Function sendMail(ByVal TemplatePath As String) As Boolean


    mailObj.sendMail(TemplatePath)


    mailObj.BodyFormat = MailFormat.Html


    SmtpMail.SmtpServer = ("mail.My Host Site.com")


    SmtpMail.Send(mailObj)


    .......


    .....


    end function





    Thanks in advanced
     
  2. When sending e-mails programmatically from a DASP server, you have to set the SMTP server to 'localhost' like this:

    SmtpMail.SmtpServer = 'localhost';

    They do this to prevent spammers from using your SMTP server to send mail.
     
Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.

Share This Page