// Note: only needed if the SMTP server requires authentication
client.Authenticate (smtp_info["SmtpServer_server_username"], smtp_info["SmtpServer_server_password"]);
var message = new MimeMessage ();
message.From.Add (new MailboxAddress ("Selexions", smtp_info["SmtpServer_server_username"]));
message.To.Add (new MailboxAddress (TO));
message.Subject = SUBJ;
message.Body = new TextPart ("plain") {
Text = MSG
};
client.Send(message);
client.Disconnect (true);
Hi there,
I get a error message on this line:message.To.Add (new MailboxAddress (TO));Error message:CS0618: MailboxAddress.MailboxAddress(string) is obsolete. This constructor will be going away due to it causing too much confusion. Use new MailboxAddress(string name, string address) of MailboxAddress.Parse(string) instead.Can anyone help me out with a fix for the obsolete MailboxAddres(TO) function?Thanks!