Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

CDO email with html code

Posted on 2004-04-28
2
Medium Priority
?
536 Views
Last Modified: 2012-08-14
trying to send this email  with html code in the body but i get this error
Microsoft VBScript compilation error '800a0401'

Expected end of statement

/2004fallregistrationnew.asp, line 148

objCDOSYSMail.HTMLBody =" Thank you very much for registering for the FC PRIDE 2004 fall try-outs. Please make sure that your player brings a ball, shin guards, and water for all try-out sessions. All sessions will take place behind the Lawrence Soccer Complex- South Concession Stand.<BR> Please arrive 30 minutes prior to your try-outs to complete your registration. <BR> Please check the FC Pride website <a href="http://www.fcpride.org/">www.fcpride.org</a> in the event of poor weather. <BR> Brent Paulson <br> <a href="mailto:bep@fcpride.org">bep@fcpride.org</a>"
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------^
this is my code ... what am i doing wrong??

'Dimension variables
Dim objCDOSYSCon
   
'Create the e-mail server object
Set objCDOSYSMail = Server.CreateObject("CDO.Message")
Set objCDOSYSCon = Server.CreateObject ("CDO.Configuration")
'Set and update fields properties
'Out going SMTP server
objCDOSYSCon.Fields("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "192.168.111.2"
'SMTP port
objCDOSYSCon.Fields("http://schemas.microsoft.com/cdo/configuration/smtpserverport")  = 25
'CDO Port
objCDOSYSCon.Fields("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
'Timeout
objCDOSYSCon.Fields("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 60
objCDOSYSCon.Fields.Update

'Update the CDOSYS Configuration
Set objCDOSYSMail.Configuration = objCDOSYSCon
'Who the e-mail is from
objCDOSYSMail.From = "bep@fcpride.org"
'Who the e-mail is sent to
objCDOSYSMail.To = request.Form("email")
'The subject of the e-mail
objCDOSYSMail.Subject = "2004 Spring Player Application Confirmation Letter"


'Set the e-mail body format (HTMLBody=HTML TextBody=Plain)
objCDOSYSMail.HTMLBody =" Thank you very much for registering for the FC PRIDE 2004 fall try-outs. Please make sure that your player brings a ball, shin guards, and water for all try-out sessions. All sessions will take place behind the Lawrence Soccer Complex- South Concession Stand.<BR> Please arrive 30 minutes prior to your try-outs to complete your registration. <BR> Please check the FC Pride website <a href="http://www.fcpride.org/">www.fcpride.org</a> in the event of poor weather. <BR> Brent Paulson <br> <a href="mailto:bep@fcpride.org">bep@fcpride.org</a>"
objCDOSYSMail.Send
Set objCDOSYSMail = Nothing
Set objCDOSYSCon = Nothing
0
Comment
Question by:gianitoo
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 33

Accepted Solution

by:
Big Monty earned 2000 total points
ID: 10944068
you need to double up the quotes:

objCDOSYSMail.HTMLBody =" Thank you very much for registering for the FC PRIDE 2004 fall try-outs. Please make sure that your player brings a ball, shin guards, and water for all try-out sessions. All sessions will take place behind the Lawrence Soccer Complex- South Concession Stand.<BR> Please arrive 30 minutes prior to your try-outs to complete your registration. <BR> Please check the FC Pride website <a href=""http://www.fcpride.org/"">www.fcpride.org</a> in the event of poor weather. <BR> Brent Paulson <br> <a href=""mailto:bep@fcpride.org"">bep@fcpride.org</a>"

B.D.
0
 
LVL 1

Author Comment

by:gianitoo
ID: 10944177
Bingo
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…

704 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question