开发者

Smtp Config in asp.Net

开发者 https://www.devze.com 2022-12-13 21:09 出处:网络
Hai, I have developed small asp.net application.i send mail through this application.so my web config file have following coding

Hai, I have developed small asp.net application.i send mail through this application.so my web config file have following coding

    <network host="smtp.gmail.com" port="587" userName="username@domainname.com" password="*****"  /&g开发者_开发百科t;
  </smtp>
</mailSettings>

we have google apps.we don't have mail server. i try to sent mail,i getting time out error. regards mariyappan.J


If you are using System.Net.Mail.MailMessage try this:

yourMailMessage.EnableSsl = true;


This could be:

  • Firewall related
  • IIS User account related
  • Have you tried smtp.googlemail.com Reading this it doesn't matter

I realise that's a bit of a generic answer but your config settings are correct so logically it can only be related to the network, or the user.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号