CDO Mail Object Help

  • Thread starter Thread starter connie
  • Start date Start date
C

connie

I have an E-mail ASP Web form that is using a CDO Mail
Object. Everything works fine with it. This form has to
be filled out before the customer can download our demo.
Currently, the customer fills out the form, clicks submit
and a message appears to the customer and an email is sent
to me. I want to modify the codes so that after the
customer clicks SUBMIT, the info is submitted and then the
download immediately begins.

What is the code I should add to begin downloading a file
after the form is successfully submitted. Here's some of
the code I am currently using:

Set objMessage = CreateObject("CDO.Message")
objMessage.Subject = "Cosmetology DEMO for " &
Request ("Department")

objMessage.From = "(e-mail address removed)"
objMessage.To = "(e-mail address removed)"
objMessage.TextBody = ("txtmsg")& " " & "Name: "
& Request("addressto")& " Dept: " & Request("Department")
& " Telephone: " & Request ("Telephone Number") & "
Email: " & Request ("Email Address") & " School Name: " &
Request ("Company/School Name") & " City/State: " &
Request ("City/State")
objMessage.Send

mailres=objMessage.Send()
if NOT mailres then
%>
<script language = "JavaScript">
<!--
alert("Your information has been sent. Click on
the Graduate Icon to complete download.");
//-->
</script>
<%
else
Response.Write "<table width=90% border=0><tr><td
bgcolor=#ffff55 align=center>Mail send
failure.</td></tr></table>"
end if
End If
%>
 
Wrong newsgroup. You're using CDO for Windows, not the Outlook component CDO
1.21. An ASP forum should be able to help you.
 
Back
Top