public void smtp_Send(object sender, SQLReference.SendEmailCompletedEventArgs e) { cli.SendEmailCompleted -= smtp_Send; if (e.Result != "Success") { cmdSendVerification.IsEnabled = true; MessageBox.Show("There was an error sending the email. Make sure the address is valid." + Environment.NewLine + Environment.NewLine + "Message: " + e.Result); } cmdSendVerification.IsEnabled = true; }
public void mailClient_smtpSent(object sender, SQLReference.SendEmailCompletedEventArgs e) { mailClient.SendEmailCompleted -= mailClient_smtpSent; if (e.Result == "Success") { MessageBox.Show("Email has been sent."); txtBody.Text = ""; txtSubject.Text = ""; } else { MessageBox.Show("There was an error sending the email." + Environment.NewLine + Environment.NewLine + "Message: " + e.Result); } }
void client_SendEmailCompleted(object sender, SQLReference.SendEmailCompletedEventArgs e) { MessageBox.Show(e.Result); }