|
 |
asp_web_howto thread: New Line In Email
Message #1 by rg1@h... on Thu, 17 May 2001 20:38:18
|
|
Hello.
I have a loop on a ASP page. Part of the code builds up a message body for
an email. This message is also displayed in the browser as part of an HTML
page, so I use <BR> at the end of each line that's built up.
This works fine in the browser but in my email that's being sent, the <BR>
shows up (of course!) and there's no "New Line" between each message part
that was built up in the loop.
What can I use as a new line indicator for display in an email message?
TIA.
Rita
Message #2 by "Pham, Khanh" <Khanh.Pham@d...> on Fri, 18 May 2001 08:56:35 -0400
|
|
Try using vbcrlf
-----Original Message-----
From: rg1@h... [mailto:rg1@h...]
Sent: Thursday, May 17, 2001 4:38 PM
To: ASP Web HowTo
Subject: [asp_web_howto] New Line In Email
Hello.
I have a loop on a ASP page. Part of the code builds up a message body
for
an email. This message is also displayed in the browser as part of an
HTML
page, so I use <BR> at the end of each line that's built up.
This works fine in the browser but in my email that's being sent, the
<BR>
shows up (of course!) and there's no "New Line" between each message
part
that was built up in the loop.
What can I use as a new line indicator for display in an email message?
TIA.
Rita
Message #3 by Kyle Burns <kburns@c...> on Fri, 18 May 2001 09:02:24 -0500
|
|
You'll need to define vbCrLf, it's not an intrinsic constant to
VBScript.
vbCrLf =3D Chr(10) & Chr(13)
>> -----Original Message-----
>> From: Pham, Khanh [mailto:Khanh.Pham@d...]
>> Sent: Friday, May 18, 2001 7:57 AM
>> To: ASP Web HowTo
>> Subject: [asp_web_howto] RE: New Line In Email
>>
>>
>> Try using vbcrlf
>>
>> -----Original Message-----
>> From: rg1@h... [mailto:rg1@h...]
>> Sent: Thursday, May 17, 2001 4:38 PM
>> To: ASP Web HowTo
>> Subject: [asp_web_howto] New Line In Email
>>
>>
>> Hello.
>>
>> I have a loop on a ASP page. Part of the code builds up a
>> message body for
>> an email. This message is also displayed in the browser as
>> part of an HTML
>> page, so I use <BR> at the end of each line that's built up.
>>
>> This works fine in the browser but in my email that's being
>> sent, the <BR>
>> shows up (of course!) and there's no "New Line" between each
>> message part
>> that was built up in the loop.
>>
>> What can I use as a new line indicator for display in an
>> email message?
>>
>> TIA.
>>
>> Rita
>>
Message #4 by Kyle Burns <kburns@c...> on Fri, 18 May 2001 09:01:25 -0500
|
|
You have two options here.
1) Send the email in HTML format. The pro for this is ease of
formatting.
The con is that some mail readers won't display it correctly.
2) Use Chr(10) in your plain text message to send line breaks.
>> -----Original Message-----
>> From: rg1@h... [mailto:rg1@h...]
>> Sent: Thursday, May 17, 2001 3:38 PM
>> To: ASP Web HowTo
>> Subject: [asp_web_howto] New Line In Email
>>
>>
>> Hello.
>>
>> I have a loop on a ASP page. Part of the code builds up a
>> message body for
>> an email. This message is also displayed in the browser as
>> part of an HTML
>> page, so I use <BR> at the end of each line that's built up.
>>
>> This works fine in the browser but in my email that's being
>> sent, the <BR>
>> shows up (of course!) and there's no "New Line" between each
>> message part
>> that was built up in the loop.
>>
>> What can I use as a new line indicator for display in an
>> email message?
>>
>> TIA.
>>
>> Rita
>
Message #5 by "Ken Schaefer" <ken@a...> on Mon, 21 May 2001 12:20:40 +1000
|
|
This is a multi-part message in MIME format.
------=_NextPart_000_0187_01C0E1F0.72F7B190
Content-Type: text/plain;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
:
: You'll need to define vbCrLf, it's not an intrinsic constant
: to VBScript.
:
: vbCrLf =3D Chr(10) & Chr(13)
:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Uh, since when?
From the docs:
Microsoft=AE Visual Basic=AE Scripting Edition
String Constants Language Reference
Version 2
-------------------------------------------------------------------------
-------
Since these constants are built into VBScript, you don't have to define
them before using them. Use them anywhere in your code to represent the
values shown for each.
Constant Value Description
vbCr Chr(13) Carriage return.
vbCrLf Chr(13) & Chr(10) Carriage return=96linefeed combination.
vbFormFeed Chr(12) Form feed; not useful in Microsoft Windows.
vbLf Chr(10) Line feed.
vbNewLine Chr(13) & Chr(10) or Chr(10) Platform-specific newline
character; whatever is appropriate for the platform.
vbNullChar Chr(0) Character having the value 0.
vbNullString String having value 0 Not the same as a zero-length
string (""); used for calling external procedures.
vbTab Chr(9) Horizontal tab.
vbVerticalTab Chr(11) Vertical tab; not useful in Microsoft
Windows.
Cheers
Ken
Message #6 by "Eric Van Camp" <eric@a...> on Fri, 18 May 2001 15:14:38 +0200
|
|
thanks to all helping me with this problem..it was my own mistake..i
defined the mail always as html mail!
txs a lot the problem is solved!
-----Original Message-----
From: Pham, Khanh [mailto:Khanh.Pham@d...]
Sent: vrijdag 18 mei 2001 14:57
To: ASP Web HowTo
Subject: [asp_web_howto] RE: New Line In Email
Try using vbcrlf
-----Original Message-----
From: rg1@h... [mailto:rg1@h...]
Sent: Thursday, May 17, 2001 4:38 PM
To: ASP Web HowTo
Subject: [asp_web_howto] New Line In Email
Hello.
I have a loop on a ASP page. Part of the code builds up a message body
for
an email. This message is also displayed in the browser as part of an
HTML
page, so I use <BR> at the end of each line that's built up.
This works fine in the browser but in my email that's being sent, the
<BR>
shows up (of course!) and there's no "New Line" between each message
part
that was built up in the loop.
What can I use as a new line indicator for display in an email message?
TIA.
Rita
|
|
 |