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

Free Support Forum - aspose.com

Aspose.Network.Mail.SmtpException on x64 environment

I'm trying to send an email using Aspose.Network (for .net 3.5) last version (5.1.0.0) and I get the following error :

Aspose.Network.Mail.SmtpException: Failure sending mail. ---> System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
at Aspose.Network.x1c9f6449504953fe.xc2f01cb70e7380c2(x808d0de58fa7b39f x808d0de58fa7b39f, Object x071bde1041617fce, Boolean x65ac3fc66e6d804e, IPAddress& x179bb663e71b1f59, Socket& x4e2d5aa89fd8e1ee, Socket& x3f9dbda316f791ce, Int32 x22eb5e43b9d27f73)
at Aspose.Network.x808d0de58fa7b39f.x5b7f6ddd07ded8cd(Object x944eceb0e7a3d715, Boolean x65ac3fc66e6d804e, Int32 x22eb5e43b9d27f73, x4b415ae1793ad6e0 x376893f20952b500)
at Aspose.Network.x808d0de58fa7b39f.x5b7f6ddd07ded8cd(Object x944eceb0e7a3d715, x4b415ae1793ad6e0 x376893f20952b500)
at Aspose.Network.xfe59f70d217c6d23.xc2f01cb70e7380c2(Object x944eceb0e7a3d715, x4b415ae1793ad6e0 x376893f20952b500, Int32 x37c223533b584379)
at Aspose.Network.Mail.xdb676c5c7502b346.xc2f01cb70e7380c2(String x64f259306803411c, Int32 x200aedbf6c3c4174)
at Aspose.Network.Mail.xe0a8a59934b83f35.xc2f01cb70e7380c2(String x64f259306803411c, Int32 x200aedbf6c3c4174)
at Aspose.Network.Mail.SmtpClient.Send(MailMessage message)

That works on 32bit environment !

Thanks

Hi,

Could you please test sending the email in a console application on 64-bit OS? I tested the following code with both .NET 2.0 and 3.5 dll, Aspose.Network 5.1 and Windows 7 x64 and I could not reproduce the problem.

SmtpClient client = new SmtpClient(“smtp.gmail.com”, 587, “user@gmail.com”, “pwd”);
client.EnableSsl = true;
client.SecurityMode = SmtpSslSecurityMode.Explicit;

MailMessage msg = new MailMessage(“user@gmail.com”, “to@gmail.com”);
msg.Subject = “Email Send Test”;
msg.Body = “This is a test”;

client.Send(msg);