Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_cdo thread: Using
tag in cdonts mail message


Message #1 by m.murray@s... on Thu, 23 Aug 2001 16:10:57
Hi there!



I am sending a new mail message to a user who has filled out a contact 

form. In the email I quote them a reference from a database and provide a 

summary of the details they submitted.



It's all working fine - only one problem - Using a <br> tag in the body of 

the message isn't starting a new line.





My code....



body = "Thank you for logging a call. Your reference is " & ref & "." &_

"<br>Listed below is a summary of your support query."&_

"<br>Problem: " & problem & ""&_

"<br>Time: " & temptime & ""





The result...



Thank you for logging a call. Your reference is 26.<br>Listed below is a 

summary of your support query.<br>Problem: Can't connect to webserver or 

SQL server. <br>Time: 15:58:54





How can I start a new line for each part of the email? My email client is 

Outlook and message type is Plain Text. Is there a way to achieve this by 

keeping the message type as Plain Text?



Cheers!



Matt







Message #2 by "Tony Diana" <tony@v...> on Thu, 23 Aug 2001 11:25:42 -0400
Try replacing the <BR> tags with the vbCR constant, like so



"This is a line of text" & vbCR _

& "This is a new line"



This will insert carraige returns, which are just plain text.



hope this helped.



-----Original Message-----

From: m.murray@s... [mailto:m.murray@s...]

Sent: Thursday, August 23, 2001 4:11 PM

To: ASP CDO

Subject: [asp_cdo] Using <br> tag in cdonts mail message





Hi there!



I am sending a new mail message to a user who has filled out a contact

form. In the email I quote them a reference from a database and provide a

summary of the details they submitted.



It's all working fine - only one problem - Using a <br> tag in the body of

the message isn't starting a new line.





My code....



body = "Thank you for logging a call. Your reference is " & ref & "." &_

"<br>Listed below is a summary of your support query."&_

"<br>Problem: " & problem & ""&_

"<br>Time: " & temptime & ""





The result...



Thank you for logging a call. Your reference is 26.<br>Listed below is a

summary of your support query.<br>Problem: Can't connect to webserver or

SQL server. <br>Time: 15:58:54





How can I start a new line for each part of the email? My email client is

Outlook and message type is Plain Text. Is there a way to achieve this by

keeping the message type as Plain Text?



Cheers!



Matt

Message #3 by m.murray@s... on Thu, 23 Aug 2001 16:37:33
Thanks Tony!

It worked a treat! :)



Matt

Message #4 by "Alex Shiell, ITS, EC, SE" <alex.shiell@s...> on Thu, 23 Aug 2001 16:37:11 +0100
use vbCrLf rather than vbCR



-----Original Message-----

From: Tony Diana [mailto:tony@v...]

Sent: 23 August 2001 16:26

To: ASP CDO

Subject: [asp_cdo] RE: Using <br> tag in cdonts mail message





Try replacing the <BR> tags with the vbCR constant, like so



"This is a line of text" & vbCR _

& "This is a new line"



This will insert carraige returns, which are just plain text.



hope this helped.



-----Original Message-----

From: m.murray@s... [mailto:m.murray@s...]

Sent: Thursday, August 23, 2001 4:11 PM

To: ASP CDO

Subject: [asp_cdo] Using <br> tag in cdonts mail message





Hi there!



I am sending a new mail message to a user who has filled out a contact

form. In the email I quote them a reference from a database and provide 

a

summary of the details they submitted.



It's all working fine - only one problem - Using a <br> tag in the body 

of

the message isn't starting a new line.





My code....



body =3D "Thank you for logging a call. Your reference is " & ref & "." 

&_

"<br>Listed below is a summary of your support query."&_

"<br>Problem: " & problem & ""&_

"<br>Time: " & temptime & ""





The result...



Thank you for logging a call. Your reference is 26.<br>Listed below is 

a

summary of your support query.<br>Problem: Can't connect to webserver 

or

SQL server. <br>Time: 15:58:54





How can I start a new line for each part of the email? My email client 

is

Outlook and message type is Plain Text. Is there a way to achieve this 

by

keeping the message type as Plain Text?



Cheers!



Matt

Message #5 by m.murray@s... on Thu, 23 Aug 2001 17:00:33
Why is vbCrLf better? 



Is Space(1) the best way to add a   ?



Cheers



Matt

  Return to Index