Thanks for the reply. I changed my asp.net code to use opensmtp instead of
System.Net.Mail but now its giving another error
"Smtp error occured: ERROR - Expecting: 250. Recieved: 530 5.7.0 Must issue
a STARTTLS command first 24sm3331267ugf"
Following is the code that I have used:
OpenSmtp.Mail.MailMessage msg = new OpenSmtp.Mail.MailMessage();
msg.AddRecipient("[EMAIL PROTECTED]",OpenSmtp.Mail.AddressType.To);
msg.From = new OpenSmtp.Mail.EmailAddress("[EMAIL PROTECTED]");
msg.Subject = "Test mail using .net2.0";
msg.Body = "This is my msg Body";
string MailServer = "smtp.gmail.com";
string MailUser = "[EMAIL PROTECTED]";
string MailPass = "xxxxx";
int MailPort = 587;
OpenSmtp.Mail.SmtpConfig.SmtpPort = 587;
OpenSmtp.Mail.SmtpConfig.SmtpHost = "smtp.gmail.com";
OpenSmtp.Mail.Smtp oSmtp = new OpenSmtp.Mail.Smtp
("smtp.gmail.com",587);//MailServer, MailUser, MailPass, MailPort);
oSmtp.Username="[EMAIL PROTECTED]";
oSmtp.Password="xxxxx";
oSmtp.SendMail(msg);
Please let me know where I am going wrong.
Thanks
From: Jorge Bastos [mailto:[EMAIL PROTECTED]
Sent: Wednesday, April 11, 2007 6:09 PM
To: Jyoti Seth
Subject: Re: [Mono-list] Sending Mails through ASP.Net on Mono Linux server
I use opensmtp.net from sf.net, my opinion, its alot better then
system.net.mail
----- Original Message -----
From: Jyoti Seth <mailto:[EMAIL PROTECTED]>
To: '[EMAIL PROTECTED]'
Sent: Wednesday, April 11, 2007 12:25 PM
Subject: [Mono-list] Sending Mails through ASP.Net on Mono Linux server
Hello,
I am using System.Net.Mail for sending mails in asp.net applications and it
is working fine on windows xp m/c. But when I publish this on suse linux
server with mono 2.0 and postfix smtp service installed and configured it
gives an error either "Unable to validate data" or "Service not available".
I have also read about sharpwebmail application on net for sending mails
through ASP.Net on linux. Please suggest what should be best to use to run
asp.net applications for sending mails on linux server.
Thanks,
Jyoti
_____
_______________________________________________
Mono-list maillist - [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list
_______________________________________________
Mono-list maillist - [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list