CDONTS problem

  • Thread starter Guatemala Balla
  • Start date
G

Guatemala Balla

Below is my code, it looks like it should work, I've used this exact
code before but this doesn't want to send and I don't know why. Can
someone take a peek see and let me know what I'm doin wrong?

Thanks

Dim Mailer
Set Mailer = Server.Createobject("CDONTS.NewMail")

If isObject(Mailer) Then
Mailer.To = CStr(Email)
Mailer.From = "(e-mail address removed)"
Mailer.Subject = "Forgotten Password"
body = "This is the body"

Mailer.TextBody = body
Mailer.Send

message = "Your password has been sent to " & Email
Server.URLEncode message
response.redirect "default.asp?message=" & message
Else
message = "There was an error in sending your password"
Server.URLEncode message
response.redirect "default.asp?message=" & message
End If
Set Mailer = Nothing
 
A

Aaron Bertrand [SQL Server MVP]

What does "doesn't want to send" mean? Do you get an error message? If so,
what is it?

Anyway, stop using CDONTS, it's been deprecated. The problem may be as
simple as, now you're running XP or Windows 2003, where CDONTS doesn't even
exist. Use cdo.message instead.

http://www.aspfaq.com/2026
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,770
Messages
2,569,583
Members
45,073
Latest member
DarinCeden

Latest Threads

Top