
I have a problem it seems that when I try to send a file in the html format it doesnot send the saved html files i have saved based on the response. For instance I have four different html emails to choose from based on the customers request. Originaly I had no problems using this code in the CDONTS format where I could tell it what type of mail it was based on the body format.By the way I'm loking for independant web developers that Know asp.net or asp to develope and maintain web sites.
Email me at
[email protected]
<%
function sendemail(cEmail,cName,cSubject,cBody,cBCC,lHTML)
On Error Resume Next
if gEmailComponent="CDO" then
Dim objCDO
Dim iConf
Dim Flds
'Const cdoSendUsingPort = 2
Set objCDO = Server.CreateObject("CDO.Message")
Set iConf = Server.CreateObject("CDO.Configuration")
'cdoSendUsingPort
Set Flds = iConf.Fields
With Flds
.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "mail-fwd"
.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
.Item("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 40
.Update
End With
Set objCDO.Configuration = iConf
objCDO.To = cEmail
objCDO.BCC = cBCC
'objCDO.Value("Reply-To") = gCompanyEmail
objCDO.From = gCompanyEmail
objCDO.Subject = cSubject
'objCDO.importance = 1
'Set body format for lHTML
if lHTML then
objCDO.HTMLBody = cBody
else
objCDO.TextBody = cBody
end if
objCDO.Send
'set objCDO = closed
'Set iConf = closed
'Set Flds = closed
'Response.redirect "confirmation.html"
' Any existing page can be used for the response redirect method
'END IF
set objCDO = nothing
Set iConf = Nothing
Set Flds = Nothing
end if
Error=Err.description
sendemail=Err=0
end Function
%>
Your help is greatly apprciated...........