Naming conventions
Naming conventions
(OP)
Hello
I am getting an error which, I suspect, is related to this:
In my form I have three fields, name, email, and message. Here I have:
Does 'From' refer to the name of the person as in 'From Joe' or Joe's email? If it refers to email, what would name be?
Thanks!
I am getting an error which, I suspect, is related to this:
CODE -->
If errorCount = 0 Then Set ObjSendMail = Server.CreateObject("CDO.Message") ObjSendMail.To = WebmasterEmail 'recipient ObjSendMail.BCC = myCopy 'other recipient ObjSendMail.From = name 'sender ObjSendMail.From = email 'sender ObjSendMail.Body = message ObjSendMail.HTMLBody = strBody ObjSendMail.Send Set ObjSendMail = Nothing End If
In my form I have three fields, name, email, and message. Here I have:
CODE -->
ObjSendMail.From = name 'sender ObjSendMail.From = email 'sender
Does 'From' refer to the name of the person as in 'From Joe' or Joe's email? If it refers to email, what would name be?
Thanks!
RE: Naming conventions
Which error ? On which line ?
I'd replace this:
ObjSendMail.From
with this:
ObjSendMail.Sender
Have a look here:
http://www.paulsadowski.com/WSH/cdo.htm
Hope This Helps, PH.
FAQ219-2884: How Do I Get Great Answers To my Tek-Tips Questions?
FAQ181-2886: How can I maximize my chances of getting an answer?
RE: Naming conventions
Yes, I can change From to Sender, but does Sender refer to the name of the sender or the email of the sender or doesn't it matter as long as I have them like this:
ObjSendMail.Sender = name 'sender
ObjSendMail.Sender = email 'sender
The actual error is pointing to:
Line 87 is this:
CODE -->
but I am not sure if that is a false message. Those are standard, aren't they? I have never touched them.
Thanks again for your reply.