https://bugzilla.novell.com/show_bug.cgi?id=651892
https://bugzilla.novell.com/show_bug.cgi?id=651892#c0 Summary: I have been trying to use the SmtpClient in System.Net.Mail in the MonoTouch Framework. Classification: Mono Product: MonoTouch Version: unspecified Platform: Other OS/Version: Other Status: NEW Severity: Critical Priority: P5 - None Component: Class Libraries AssignedTo: [email protected] ReportedBy: [email protected] QAContact: [email protected] Found By: Third Party Developer/Partner Blocker: Yes Description of Problem: When i try to use the SmtpClient to send emails, if i use the SmtpClient.Send() method, it just hangs the thread, if i try to use SmtpClient.SendAsync() it doesn't error out, but never returns on the Async call. Steps to reproduce the problem: <Code Sample> void SendNotificationEmail(NSData attachment) { MailMessage mm = new MailMessage(); mm.To.Add(new MailAddress(Application.NotificationEmail)); mm.From = new MailAddress("[email protected]"); mm.Bcc.Add(new MailAddress("[email protected]")); mm.Subject = "Customer Signup CSV Export"; mm.Body = "Here are the Customers Signed up"; mm.Attachments.Add(new Attachment(attachment.AsStream(), "text/csv")); mm.BodyEncoding = UTF8Encoding.UTF8; mm.DeliveryNotificationOptions = DeliveryNotificationOptions.OnFailure; NetworkCredential _Credential = new NetworkCredential("test", "test"); SmtpClient ss = new SmtpClient("smtp.gmail.com"); ss.UseDefaultCredentials = false; ss.EnableSsl = true; ss.Credentials = _Credential; ss.Port = 465; ss.SendCompleted+= HandleSsSendCompleted; object userToken = mm; ss.SendAsync(mm, userToken); } void HandleSsSendCompleted (object sender, System.ComponentModel.AsyncCompletedEventArgs e) { if(e.Error != null) { Util.SuccessfulMessage("Error Occurred"); } } 2. Actual Results: HandleSsSendCompleted event never gets called. Expected Results: HandleSsSendCompleted event should get called. How often does this happen? Always Additional Information: I can be found on #monotouch IRC channel as SuperYeti -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug. You are the assignee for the bug. _______________________________________________ mono-bugs maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-bugs
