|
 |
access_asp thread: Trouble with CDONT Mail
Message #1 by "Paul Forman" <pwog@m...> on Sat, 19 Oct 2002 02:50:32
|
|
Hi,
I have a site that a user can input into a database and then is
redirected to a "thankyou.asp" page which gives them their reference
number (pulled from the database. I also set up a CDONT mail so that
when "thankyou.asp" loads an email is sent telling me that a new
record was entered and giving me the reference number as well.
Everything works fine, except the email I receive is blank. Here is
the code I am using: Can someone help me out?
<%
Dim objCDO, UserEmail, UserFname, UserLname, Reference
UserEmail = Request.Form ("strEmail")
UserFname = Request.Form ("strFirstName")
UserLname = Request.Form ("strLastName")
Reference = Request.Form ("strSellerID")
Set objCDO = Server.CreateObject("CDONTS.NewMail")
objCDO.From = "postmaster@l..."
objCDO.Subject = "A New Record Was Just Added"
objCDO.To = "admin@l..."
objCDO.Body = UserEmail &" "& Reference
objCDO.Send
Set objCDO = Nothing
%>
Thanks - Paul
Message #2 by "Ken Schaefer" <ken@a...> on Mon, 21 Oct 2002 11:22:32 +1000
|
|
Is there anything in Request.Form("strEmail") etc.
If not, then your email will be blank no?
Cheers
Ken
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: "Paul Forman" <pwog@m...>
Subject: [access_asp] Trouble with CDONT Mail
: I have a site that a user can input into a database and then is
: redirected to a "thankyou.asp" page which gives them their reference
: number (pulled from the database. I also set up a CDONT mail so that
: when "thankyou.asp" loads an email is sent telling me that a new
: record was entered and giving me the reference number as well.
:
: Everything works fine, except the email I receive is blank. Here is
: the code I am using: Can someone help me out?
:
: <%
: Dim objCDO, UserEmail, UserFname, UserLname, Reference
: UserEmail = Request.Form ("strEmail")
: UserFname = Request.Form ("strFirstName")
: UserLname = Request.Form ("strLastName")
: Reference = Request.Form ("strSellerID")
: Set objCDO = Server.CreateObject("CDONTS.NewMail")
: objCDO.From = "postmaster@l..."
: objCDO.Subject = "A New Record Was Just Added"
: objCDO.To = "admin@l..."
: objCDO.Body = UserEmail &" "& Reference
: objCDO.Send
: Set objCDO = Nothing
: %>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Message #3 by "polly" <chinahongkong@h...> on Tue, 22 Oct 2002 18:01:57
|
|
Hello....
maybe use one more variable...
dim body as string
then make some change
body = UserEmail &" "& Reference
bjCDO.Body = body
bjCDO.send
try it..hope it can help u...
>
H> i,
> I have a site that a user can input into a database and then is
r> edirected to a "thankyou.asp" page which gives them their reference
n> umber (pulled from the database. I also set up a CDONT mail so that
w> hen "thankyou.asp" loads an email is sent telling me that a new
r> ecord was entered and giving me the reference number as well.
> Everything works fine, except the email I receive is blank. Here is
t> he code I am using: Can someone help me out?
> <%
D> im objCDO, UserEmail, UserFname, UserLname, Reference
U> serEmail = Request.Form ("strEmail")
U> serFname = Request.Form ("strFirstName")
U> serLname = Request.Form ("strLastName")
R> eference = Request.Form ("strSellerID")
S> et objCDO = Server.CreateObject("CDONTS.NewMail")
o> bjCDO.From = "postmaster@l..."
o> bjCDO.Subject = "A New Record Was Just Added"
o> bjCDO.To = "admin@l..."
o> bjCDO.Body = UserEmail &" "& Reference
o> bjCDO.Send
S> et objCDO = Nothing
%> >
> Thanks - Paul
|
|
 |