Results 1 to 2 of 2

Thread: How to formatt email using CDO?

  1. #1

    Thread Starter
    PowerPoster
    Join Date
    Jan 2001
    Location
    Florida
    Posts
    3,216

    Talking

    How do I format my textbody to have line breaks like the following?

    Example:

    hello!

    Your name goes here,

    and

    here.

    Here is my code I am using so far.
    I don't want all the text to word wrap.


    Code:
    '--sends email to Client
        	
       	Set objCDO = Server.CreateObject("CDO.Message")
    
    		objCDO.From = "returnemail"
    		objCDO.To = Request.Form("email")
    		objCDO.cc = "email, email"
    
    	Dim txtSubject
    	
    		txtSubject = "Your registration " & Request.Form("name1") & " " & Request.Form("name") & " has been received. Your UserID is " & Request.Form("userID") & " Your Password is " & Request.Form("password") & " Please keep this email for future reference. "
    		objCDO.Subject = "Center for blah blah blah " & Request.Form("name1") & " " & Request.Form("name") 
    		objCDO.TextBody = txtSubject
    		objCDO.Send
    		
        	Set objCDO = nothing

  2. #2
    Addicted Member Active's Avatar
    Join Date
    Jan 2001
    Location
    Lat: 13° 4' 46" N, Long: 80° 15' 20" E
    Posts
    209
    txtSubject = "hello!" & vbCrlf & "Your name goes here, " & vbcrlf & _
    "and " & vbCrlf & "here. "
    If you can't beat your computer at chess, try kickboxing !!!
    [Download Tag Editing Tools.]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width