2

I installed on a server windows server 2008 service SmarterMail. Configured interface and works perfectly. I created a software in .net c # here's the code:

           MailMessage mail = new MailMessage();
            mail.From = new MailAddress("[email protected]", "Prova");
            foreach (string recips in email)
            {
                mail.To.Add(recips);
            }
            mail.Subject = "PRova";
            mail.BodyEncoding = System.Text.Encoding.UTF8;
            mail.IsBodyHtml = true;
            mail.Body = messaggio;
            foreach (string itemurl in file)
            {
                System.Net.Mail.Attachment attachment;
                attachment = new System.Net.Mail.Attachment(itemurl);
                mail.Attachments.Add(attachment);
            }
            SmtpClient smtp = new SmtpClient(server);
            smtp.UseDefaultCredentials = false;
            smtp.Credentials = new NetworkCredential("prova", "prova");
            smtp.Send(mail);

The problem is when I send email to an address @ gmail.com. The emails come in all domains except for gmail. What can be the reason?

2
  • Can you send such a mail from the same host with the same sender address to the same receiver using another mail client (Outlook, Thunderbird, whatever)? Commented May 20, 2015 at 13:47
  • 1
    are you certain it is not being marked as spam? Commented May 20, 2015 at 13:47

2 Answers 2

3

If the email works in all domains accept gmail. I would check if you have been black listed by gmail.

This doesn't seem like a issue with code.

That message tells you that you've basically have been blocked. I'd suggest not to focus on your code but to focus on what google's response is to you being blocked.

Sign up to request clarification or add additional context in comments.

Comments

0

This is the response of google server....

[2015.05.20] 16:43:03 [11057] RSP: 354 Go ahead r1si4209019wic.9 - gsmtp [2015.05.20] 16:43:03 [11057] RSP: 421-4.7.0 [ 15] Our system has detected an unusual rate of [2015.05.20] 16:43:03 [11057] RSP: 421-4.7.0 unsolicited mail originating from your IP address. To protect our [2015.05.20] 16:43:03 [11057] RSP: 421-4.7.0 users from spam, mail sent from your IP address has been temporarily [2015.05.20] 16:43:03 [11057] RSP: 421-4.7.0 rate limited. Please visit [2015.05.20] 16:43:03 [11057] RSP: 421-4.7.0 http://www.google.com/mail/help/bulk_mail.html to review our Bulk [2015.05.20] 16:43:03 [11057] RSP: 421 4.7.0 Email Senders Guidelines. r1si4209019wic.9 - gsmtp

1 Comment

Looks like they are protecting the users that your sending to on gmail. Which means you've been flagged as spam.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.