We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Aspose.Network.Mail.SmtpException was unhandled

Hi!

I created a little application with sending emails asynchronously.



SmtpClient client = new SmtpClient(…);

client.SendCompleted += client_SendCompleted;

MailMessage msg = new MailMessage();



msg.Attachments.Add("…");

client.SendAsync(msg, “test-user”);

DialogResult dialogResult = MessageBox.Show(“Stop sending”, “Test”, MessageBoxButtons.YesNo);

if (dialogResult == DialogResult.Yes)

{

client.SendAsyncCancel();

}



When I send email with attachment and try to cancel it Aspose.Network throw exception:

Aspose.Network.Mail.SmtpException was unhandled

Message=“The operation was aborted.”

Source=“Aspose.Network”



What am I doing wrong?



.Net 2.0

Aspose.Network - v4.5.0.0



Thanks.

Hi,

We are looking into it and will get back to you soon.

Hi.



Thank you.