我正在尝试使用 asp classic 发送电子邮件。使用下面的代码,我没有错误。但是电子邮件根本没有到达。所有消息都直接发送到我的 BadMail 文件夹。关于为什么会发生这种情况的任何想法?
<%
Set ObjSendMail = CreateObject("CDO.Message")
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
ObjSendMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverpickupdirectory") = "d:\Inetpub\mailroot\Pickup"
ObjSendMail.Configuration.Fields.Update
ObjSendMail.From = "myemail@domain.com"
ObjSendMail.To = "targetemail@anotherdomain.com"
ObjSendMail.Subject = "TEST EMAIL"
ObjSendMail.TextBody="This is a message."
ObjSendMail.Send
set ObjSendMail=nothing
%>