T
tshad
I am trying to run a test sending mail using CDONTS on my W2K3
machine.
It works fine running from my WXP Pro, but I don't recieve the mail if
run the W2K3 machine.
Both machines have IIS configured essentially the same.
******************************************************************************************
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
<title>Untitled Document</title>
</head>
<body>
<%
response.write("Before Request.ServerVariables variable = " &
Request.ServerVariables("LOCAL_ADDR") & "<br>")
response.write("after Request.ServerVariables variable = " &
Request.ServerVariables("LOCAL_ADDR") & "<br>")
Dim iMsg
Dim iConf
Dim Flds
Dim strHTML
Const cdoSendUsingPickup = 1
set iMsg = CreateObject("CDO.Message")
set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields
With Flds
.Item("http://schemas.microsoft.com/cdo/configuration/sendusing")
= cdoSendUsingPickup
' TODO: Replace <PICKUP DIRECTORY> with path to your
pickup directory
' Typically, c:\Inetpub\mailroot\pickup
.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverpickupdirectory")="C:\Inetpub\mailroot\pickup"
.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver")="smtp.interez.com"
.Update
End With
Dim iBP
With iMsg
Set .Configuration = iConf
.To = "(e-mail address removed)"
.From = "(e-mail address removed)"
.Subject = "A test page"
.HTMLBody = "This is a test page"
'TODO: if adding an attachment,
'uncomment the next line and alter file path as required
'Set iBP = iMsg.AddAttachment(App.Path & "\file1.txt")
.Send
End With
' Clean up variables.
Set iBP = Nothing
Set iMsg = Nothing
Set iConf = Nothing
Set Flds = Nothing
%>
</body>
</html>
**************************************************************************
Is there something in Exchange that might be giving me a problem.
Exchange is not running on either machine.
Thanks,
Tom.
machine.
It works fine running from my WXP Pro, but I don't recieve the mail if
run the W2K3 machine.
Both machines have IIS configured essentially the same.
******************************************************************************************
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
<title>Untitled Document</title>
</head>
<body>
<%
response.write("Before Request.ServerVariables variable = " &
Request.ServerVariables("LOCAL_ADDR") & "<br>")
response.write("after Request.ServerVariables variable = " &
Request.ServerVariables("LOCAL_ADDR") & "<br>")
Dim iMsg
Dim iConf
Dim Flds
Dim strHTML
Const cdoSendUsingPickup = 1
set iMsg = CreateObject("CDO.Message")
set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields
With Flds
.Item("http://schemas.microsoft.com/cdo/configuration/sendusing")
= cdoSendUsingPickup
' TODO: Replace <PICKUP DIRECTORY> with path to your
pickup directory
' Typically, c:\Inetpub\mailroot\pickup
.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverpickupdirectory")="C:\Inetpub\mailroot\pickup"
.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver")="smtp.interez.com"
.Update
End With
Dim iBP
With iMsg
Set .Configuration = iConf
.To = "(e-mail address removed)"
.From = "(e-mail address removed)"
.Subject = "A test page"
.HTMLBody = "This is a test page"
'TODO: if adding an attachment,
'uncomment the next line and alter file path as required
'Set iBP = iMsg.AddAttachment(App.Path & "\file1.txt")
.Send
End With
' Clean up variables.
Set iBP = Nothing
Set iMsg = Nothing
Set iConf = Nothing
Set Flds = Nothing
%>
</body>
</html>
**************************************************************************
Is there something in Exchange that might be giving me a problem.
Exchange is not running on either machine.
Thanks,
Tom.