[ASP]windows2008R2 서버에서 cdo.message 사용시 에러 [CDO.Message.1 error '80040222' ]
메일 소스를 이용해서 보내게 되면
CDO.Message.1 error '80040222'
The pickup directory path is required and was not specified.
이러한 오류가 있을 경우
[소스]
Const cdoSendUsingPort = 1 ' 상수선언 (로컬셋팅)
SET objMessage = Server.CreateObject("CDO.Message")
SET objConfig = createobject("CDO.Configuration")
'''''''''''''''''' Setting the SMTP Server ''''''''''''''''''''''''
SET Flds = objConfig.Fields
With Flds
.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = cdoSendUsingPort
.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "localhost"
.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
.Item("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 30
.update
End With
SET objMessage.Configuration = objConfig
With objMessage
.From = "
[email protected]"
.To = "
[email protected]"
.CC = ""
.Subject = "hello world"
.HTMLBody = "hello wolrd"
.DSNOptions = 14
.Fields("urn:schemas:mailheader:return-receipt-to") = "
[email protected]"
.Fields("urn:schemas:mailheader:disposition-notification-to") = "
[email protected]"
.BodyPart.Charset="ks_c_5601-1987"
.HTMLBodyPart.Charset="ks_c_5601-1987"
.Fields.update
.Send
End With
SET objConfig = Nothing
SET objMessage = Nothing