Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Newline Character in Access 1

Status
Not open for further replies.

bernie10

Technical User
Joined
Sep 13, 2004
Messages
219
Location
US
I have got a form that sends out an email from outlook according to email addresses in a table when a button is pressed. I have one string variable that will be the message body. Let Mailoutlook be an outlook mail item:

Code:
With Mailoutlook
   .To = rs!Email
   .Subject = "Test message- Please delete"
   .Body = mess_body
   .Send
End With

My question is how to get a newline character in the message body string.

I would have thought it would have been

Code:
mess_body = "This is the first line. \n This is the second line"

but this doesn't work. I've also tried \t, the html tag <br>, with no luck. Does anybody know the answer?

Thanks.
 
hi,
Code:
mess_body = "This is the first line." & vbCrLf &  "This is the second line"

Skip,

[glasses] [red]Be advised:[/red] It's been reported that a wee psychic is roaming the countryside.
Small Medium @ Large! [tongue]
 
Thanks figured it would be something easy.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top