-1

When I am trying to sending mail from local PC . The error

Server Has exceeded SSP rate limit.

Keeps coming. When I upload the same to my cloud server and sending mail from there , it works perfectly . why I am getting this issue. This is the code I'm using to send the mail.

        MailMessage objMailMsg;
    Mail objMail = new Mail();
    ClsCommonFunctions objMessage = new ClsCommonFunctions();

    objMailMsg = new MailMessage();

    objMailMsg.To.Add(to.Trim());
    objMailMsg.From = new MailAddress("xxx@xx.com", "xxxxx");
    objMailMsg.Subject = subject;
    objMailMsg.Body = body;

    objMailMsg.IsBodyHtml = true;
    objMailMsg.BodyEncoding = System.Text.Encoding.GetEncoding("windows-1256");



    objMailMsg.Headers.Add("Disposition-Notification-To", "xxx@xxx.com");

    SmtpClient smtp = new SmtpClient("yyyy.com");

    smtp.Port = 25;
    smtp.Credentials = new System.Net.NetworkCredential("xxx@xxx.com", "password");

    try
    {
        smtp.Send(objMailMsg);

    }
    catch (Exception ex)
    {
        objMessage.show_message(this, ex.Message);
    }

    Thread.Sleep(1000);

    objMailMsg.To.Clear();
    objMailMsg.Dispose();
Nidhin
  • 11
  • 1
  • 3
  • Your mail server probably just won't allow you to send from your IP address, you need to ask them, not Stack Overflow. – DavidG Mar 31 '17 at 11:29
  • @DavidG Some times its works perfectly . But sometimes not. Usually its after sending some mails , the problem happens – Nidhin Mar 31 '17 at 11:31
  • 1
    You still need to ask them, we can't help with your mail provider config. – DavidG Mar 31 '17 at 11:36
  • The message says you exceeded your rate limit. That means, you tried to send too many emails at once. Of course, it could be that your limit is 0. Only your provider can answer what that limit is. Either implement a throttling mechanism or retry when that error occurs after a sufficient delay – Panagiotis Kanavos Mar 31 '17 at 11:45
  • @DavidG thanks its solved . – Nidhin Mar 31 '17 at 11:50

1 Answers1

0

Check with your SMTP provider if you can send emails from elsewhere than his network. External access is often blocked.

greyxit
  • 693
  • 3
  • 13