Dear Folks,
We are experiencing a huge problem over here, although we temporarily solved it now. We create applications which combine the power of ASP and FLASH MX with these cooperating closely together. For our web based forms (information/contact forms) we always used the code below (below error code). This has always worked just perfectly until a few days ago, when we received an error for every form we had.. When we execute the form, we get this error in our browser:
CDO.Message.1 error '80040220'
The "SendUsing" configuration value is invalid.
/asp/sendmails.asp, line 69
Line 69: Set objMail_Registrant = CreateObject("CDO.Message")
An example of the complete code we are using:
*********************************************
<%
dim strREmailAdminister, strR_Naam, strR_Emailadres, strR_Telefoonnummer, strR_Aantal, strR_Datum, strR_Tijd
strREmailAdminister="lunch@fictief-restaurant.nl"
strR_Naam=Request("r_naam")
strR_Emailadres=Request("r_emailadres")
strR_Telefoonnummer=Request("r_telefoonnummer")
strR_Aantal=Request("r_aantal")
strR_Datum=Request("r_datum")
strR_Tijd=Request("r_tijd")
dim HtmlStartTags, HtmlEndTags
HtmlStartTags = "<html><body>"
HtmlEndTags = "</body></html>"
dim objMail_Registrant
Set objMail_Registrant = CreateObject("CDO.Message")
Dim sendersname_Registrant
sendersname_Registrant = "Fictief Restaurant"
finalsendersname_Registrant = """" & sendersname_Registrant & """ <" & Trim(strREmailAdminister) & ">"
objMail_Registrant.To = Trim(strR_Emailadres)
objMail_Registrant.From = Trim(finalsendersname_Registrant)
objMail_Registrant.Sender = Trim(finalsendersname_Registrant)
objMail_Registrant.Subject = "Dank u voor uw reservering"
objMail_Registrant.HTMLBody = HtmlStartTags & "<FONT SIZE='2' FACE='ARIAL'><p>Hartelijk dank voor uw reservering bij BlABlA !<br>Wij zullen uw reservering zo spoedig mogelijk per E-mail of telefoon bevestigen.</p><p>U heeft gereserveerd voor: " & strR_Datum & " om " & strR_Tijd & " uur.</p><p> </p><p>Met vriendelijke groet,<br><br>Het Team van bla bla</p></font>" & HtmlEndTags
objMail_Registrant.Send
Set objMail_Registrant= Nothing
%>
*********************************************
This has always worked fine. We are using a Windows 2000 webserver now for years and are running IIS (of course) to handle the mail for example. The funny thing is (frustrating as well) is that these forms DO work when I add the next LARGE piece of code at the beginning (top) of my code (found it somewhere on MSDN site):
*********************************************
response.Expires = -1000
Const cdoSendUsingMethod = _
"Const cdoSendUsingPort = 2
Const cdoSMTPServer = _
"Const cdoSMTPServerPort = _
"Const cdoSMTPConnectionTimeout = _
"Const cdoSMTPAuthenticate = _
"Const cdoBasic = 1
Const cdoSendUserName = _
"Const cdoSendPassword = _
"
Dim objConfig ' As CDO.Configuration
Dim objMessage ' As CDO.Message
Dim Fields ' As ADODB.Fields
' Get a handle on the config object and it's fields
Set objConfig = Server.CreateObject("CDO.Configuration")
Set Fields = objConfig.Fields
' Set config fields we care about
With Fields
.Item(cdoSendUsingMethod) = cdoSendUsingPort
.Item(cdoSMTPServer) = "smtp.inconel.nl"
.Item(cdoSMTPServerPort) = 25
.Item(cdoSMTPConnectionTimeout) = 10
.Item(cdoSMTPAuthenticate) = cdoBasic
.Update
End With
Set objMessage = Server.CreateObject("CDO.Message")
Set objMessage.Configuration = objConfig
*********************************************
AND NOW IT WORKS !!!! :S ...
Now have I searched for information about updates on IIS, SMTP or ASP etc but I can't find any announcements of changes therein which could explain this need to add code... I don't get why I have to add the above lines now all a suddenly !!
My question is, if this is just me (maybe this only happens to my own form) or that there's another cause... Could some1 please explain this to me ?????
Thnx !!!!
Gr
ROEL
We are experiencing a huge problem over here, although we temporarily solved it now. We create applications which combine the power of ASP and FLASH MX with these cooperating closely together. For our web based forms (information/contact forms) we always used the code below (below error code). This has always worked just perfectly until a few days ago, when we received an error for every form we had.. When we execute the form, we get this error in our browser:
CDO.Message.1 error '80040220'
The "SendUsing" configuration value is invalid.
/asp/sendmails.asp, line 69
Line 69: Set objMail_Registrant = CreateObject("CDO.Message")
An example of the complete code we are using:
*********************************************
<%
dim strREmailAdminister, strR_Naam, strR_Emailadres, strR_Telefoonnummer, strR_Aantal, strR_Datum, strR_Tijd
strREmailAdminister="lunch@fictief-restaurant.nl"
strR_Naam=Request("r_naam")
strR_Emailadres=Request("r_emailadres")
strR_Telefoonnummer=Request("r_telefoonnummer")
strR_Aantal=Request("r_aantal")
strR_Datum=Request("r_datum")
strR_Tijd=Request("r_tijd")
dim HtmlStartTags, HtmlEndTags
HtmlStartTags = "<html><body>"
HtmlEndTags = "</body></html>"
dim objMail_Registrant
Set objMail_Registrant = CreateObject("CDO.Message")
Dim sendersname_Registrant
sendersname_Registrant = "Fictief Restaurant"
finalsendersname_Registrant = """" & sendersname_Registrant & """ <" & Trim(strREmailAdminister) & ">"
objMail_Registrant.To = Trim(strR_Emailadres)
objMail_Registrant.From = Trim(finalsendersname_Registrant)
objMail_Registrant.Sender = Trim(finalsendersname_Registrant)
objMail_Registrant.Subject = "Dank u voor uw reservering"
objMail_Registrant.HTMLBody = HtmlStartTags & "<FONT SIZE='2' FACE='ARIAL'><p>Hartelijk dank voor uw reservering bij BlABlA !<br>Wij zullen uw reservering zo spoedig mogelijk per E-mail of telefoon bevestigen.</p><p>U heeft gereserveerd voor: " & strR_Datum & " om " & strR_Tijd & " uur.</p><p> </p><p>Met vriendelijke groet,<br><br>Het Team van bla bla</p></font>" & HtmlEndTags
objMail_Registrant.Send
Set objMail_Registrant= Nothing
%>
*********************************************
This has always worked fine. We are using a Windows 2000 webserver now for years and are running IIS (of course) to handle the mail for example. The funny thing is (frustrating as well) is that these forms DO work when I add the next LARGE piece of code at the beginning (top) of my code (found it somewhere on MSDN site):
*********************************************
response.Expires = -1000
Const cdoSendUsingMethod = _
"Const cdoSendUsingPort = 2
Const cdoSMTPServer = _
"Const cdoSMTPServerPort = _
"Const cdoSMTPConnectionTimeout = _
"Const cdoSMTPAuthenticate = _
"Const cdoBasic = 1
Const cdoSendUserName = _
"Const cdoSendPassword = _
"
Dim objConfig ' As CDO.Configuration
Dim objMessage ' As CDO.Message
Dim Fields ' As ADODB.Fields
' Get a handle on the config object and it's fields
Set objConfig = Server.CreateObject("CDO.Configuration")
Set Fields = objConfig.Fields
' Set config fields we care about
With Fields
.Item(cdoSendUsingMethod) = cdoSendUsingPort
.Item(cdoSMTPServer) = "smtp.inconel.nl"
.Item(cdoSMTPServerPort) = 25
.Item(cdoSMTPConnectionTimeout) = 10
.Item(cdoSMTPAuthenticate) = cdoBasic
.Update
End With
Set objMessage = Server.CreateObject("CDO.Message")
Set objMessage.Configuration = objConfig
*********************************************
AND NOW IT WORKS !!!! :S ...
Now have I searched for information about updates on IIS, SMTP or ASP etc but I can't find any announcements of changes therein which could explain this need to add code... I don't get why I have to add the above lines now all a suddenly !!
My question is, if this is just me (maybe this only happens to my own form) or that there's another cause... Could some1 please explain this to me ?????
Thnx !!!!
Gr
ROEL