What is the code to send an email from an ASP.NET application?
mail message = new mail(); message.From = “abc@gmail.com”; message.To = “xyz@gmail.com”; message.Subject = “Test”; message.Body = “hello”; SmtpMail.SmtpServer = “localhost”; SmtpMail.Send(message); To send an email from an ASP.NET application, you can use the SmtpClient class available in the System.Net.Mail namespace. Here’s a simple example of how you can send an email using ASP.NET: csharpCopy code … Read more