我有Windows 7.0 Enterprise,我已经从http://www.microsoft.com/en-gb/download/details.aspx?id=7887
安装了远程服务器管理工具我还将IIS配置为使用Localhost作为SMTP服务器:http://technet.microsoft.com/en-us/library/cc753146(v=ws.10).aspx
var smtpSender = new SmtpSender("localhost");
smtpSender.UserName = this._emailAccount.EmailAddress;
smtpSender.Password = this._emailAccount.Password;
smtpSender.Send(fromEmail,
toEmail,
subject,
body);
但是当我尝试发送电子邮件时,会抛出以下异常:
An attempt was made to access a socket in a way forbidden by its access permissions 127.0.0.1:25
我已经看到其他帖子说我应该安装新的SMTP服务器,但我已经安装了适用于Windows 7.0的远程服务器管理工具。它不包含SMTP服务器吗?
安装远程服务器管理工具只会向IIS添加一个新的管理单元,并且不会在本地安装任何SMTP服务器吗?