https://bugzilla.novell.com/show_bug.cgi?id=637205
https://bugzilla.novell.com/show_bug.cgi?id=637205#c0 Summary: System.Net.Mail.Credentials is giving an error on compile Classification: Mono Product: MonoTouch Version: unspecified Platform: Macintosh OS/Version: Mac OS X 10.6 Status: NEW Severity: Major Priority: P5 - None Component: Class Libraries AssignedTo: [email protected] ReportedBy: [email protected] QAContact: [email protected] Found By: Development Blocker: --- Description of Problem: System.Net.Mail.Credentials is giving an error on compile - When the line below is compiled, smtpServer.Credentials = new NetworkCredential("[email protected]", "pass0123"); it get the error: Cannot implicitly convert type System.Net.NetworkCredential to System.Net.IcredentialsByHost. An explicit conversion exists (are you missing a cast?) Steps to reproduce the problem: 1. Run the sample code i provide below in a blank project 2. See the Debugger error on compile Actual Results: Expected Results: How often does this happen? Every time Additional Information: Test code is as follows: using system.net.mail; submitButton.TouchUpInside += delegate { string to = "[email protected]"; string from = "[email protected]"; string subject = "Using the new SMTP client."; string body = @"Hello World"; MailMessage message = new MailMessage(from, to, subject, body); SmtpClient smtpServer = new SmtpClient("mail.greenpercussion.com"); smtpServer.Port = 25; smtpServer.Credentials = new NetworkCredential("[email protected]", "pass0123"); try { smtpServer.Send(message); } catch (Exception ex) { Console.WriteLine("Exception caught in CreateTestMessage1(): {0}", ex.ToString() ); } }; -- 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
