473,403 Members | 2,284 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,403 software developers and data experts.

vbCrLf

What is this? vbCrLf
May 9 '07 #1
14 5070
vbCrLf = Visual Basic Carriage Return Line Feed.


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message news:us**************@TK2MSFTNGP03.phx.gbl...
What is this? vbCrLf

May 9 '07 #2
It's like hitting the 'Enter' key, man . . . .

"dancer" <da****@microsoft.comwrote in message
news:us**************@TK2MSFTNGP03.phx.gbl...
What is this? vbCrLf

May 9 '07 #3
Then why do I not get new lines with this code?

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an ASP.NET " &
_
"Wheeler's Accident Investigation Form" & _
vbCrLf &vbCrLf & _
Check1.Text & "." & vbCrLf & vbCrLf & _
vbCrLf &vbCrLf & _
Check2.Text & vbCrLf

"Juan T. Llibre" <no***********@nowhere.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
vbCrLf = Visual Basic Carriage Return Line Feed.


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message
news:us**************@TK2MSFTNGP03.phx.gbl...
>What is this? vbCrLf


May 9 '07 #4
If you look in your source code (view source) you will see new lines.

In order to put lines in the rendered output, then you really need a BR tag.
<br />

--
Best regards,
Dave Colliver.
http://www.AshfieldFOCUS.com
~~
http://www.FOCUSPortals.com - Local franchises available
"dancer" <da****@microsoft.comwrote in message
news:O0**************@TK2MSFTNGP04.phx.gbl...
Then why do I not get new lines with this code?

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an ASP.NET "
& _
"Wheeler's Accident Investigation Form" & _
vbCrLf &vbCrLf & _
Check1.Text & "." & vbCrLf & vbCrLf & _
vbCrLf &vbCrLf & _
Check2.Text & vbCrLf

"Juan T. Llibre" <no***********@nowhere.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
>vbCrLf = Visual Basic Carriage Return Line Feed.


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message
news:us**************@TK2MSFTNGP03.phx.gbl...
>>What is this? vbCrLf



May 9 '07 #5
But you don't use <brin VB do you? Only in HTML?
"David" <da*****************@revilloc.REMOVETHIS.comwrot e in message
news:ed*************@TK2MSFTNGP04.phx.gbl...
If you look in your source code (view source) you will see new lines.

In order to put lines in the rendered output, then you really need a BR
tag. <br />

--
Best regards,
Dave Colliver.
http://www.AshfieldFOCUS.com
~~
http://www.FOCUSPortals.com - Local franchises available
"dancer" <da****@microsoft.comwrote in message
news:O0**************@TK2MSFTNGP04.phx.gbl...
>Then why do I not get new lines with this code?

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an ASP.NET "
& _
"Wheeler's Accident Investigation Form" & _
vbCrLf &vbCrLf & _
Check1.Text & "." & vbCrLf & vbCrLf & _
vbCrLf &vbCrLf & _
Check2.Text & vbCrLf

"Juan T. Llibre" <no***********@nowhere.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
>>vbCrLf = Visual Basic Carriage Return Line Feed.


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message
news:us**************@TK2MSFTNGP03.phx.gbl...
What is this? vbCrLf



May 9 '07 #6
"dancer" <da****@microsoft.comwrote in message
news:O0**************@TK2MSFTNGP04.phx.gbl...
Then why do I not get new lines with this code?
Because vbCrLf isn't HTML... :-)

Use <br /instead.
--
http://www.markrae.net

May 9 '07 #7
Probably because you're writing HTML.

vbCrLf only works within VB.NET code.

If you're writing HTML, use <br:

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an ASP.NET " & _
"Wheeler's Accident Investigation Form" & "<br>" & Check1.Text & "." & "<br>" & Check2.Text & "<br>"


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message news:O0**************@TK2MSFTNGP04.phx.gbl...
Then why do I not get new lines with this code?

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an ASP.NET " & _
"Wheeler's Accident Investigation Form" & _
vbCrLf &vbCrLf & _
Check1.Text & "." & vbCrLf & vbCrLf & _
vbCrLf &vbCrLf & _
Check2.Text & vbCrLf

"Juan T. Llibre" <no***********@nowhere.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
>vbCrLf = Visual Basic Carriage Return Line Feed.


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message news:us**************@TK2MSFTNGP03.phx.gbl...
>>What is this? vbCrLf



May 9 '07 #8
On May 9, 7:44 pm, "dancer" <dan...@microsoft.comwrote:
But you don't use <brin VB do you? Only in HTML?
when you have

objMM.BodyFormat = MailFormat.Html

you have to use HTML - so, you have to use a <brtag

when you will change

objMM.BodyFormat = MailFormat.Text

you can use vbCrLf to make new lines.

In this case your email message will be sent as a plain text.

May 9 '07 #9
I am confused.

You will notice that this is VB, not HTML. What do I use so that
Location.Text and Check1.Text and Check2.Text will be on a new line when
they appear in the e-mail?

<script language="VB" runat="server">
Sub btnSendFeedback_Click(sender as Object, e as EventArgs)

'Create an instance of the MailMessage class
Dim objMM as New MailMessage()

'Set the properties - send the email to the person who filled out
the
'feedback form.
objMM.To = xx****@xxxxxx.com

objMM.From = "xx******@xxxxxxxx.com"
'send in html format
objMM.BodyFormat = MailFormat.Html
'Set the priority - options are High, Low, and Normal
objMM.Priority = MailPriority.Normal

'Set the subject
objMM.Subject = "Accident Investigation Form"

'Set the body
objMM.Body = DateTime.Now + " " & _
Location.Text & _
vbCrLf & vbCrLf & _
Check1.Text & "." & vbCrLf & vbCrLf & _
vbCrLf &vbCrLf & _
Check2.Text & vbCrLf

'Specify to use the default Smtp Server
SmtpMail.SmtpServer = ""
'Now, to send the message, use the Send method of the SmtpMail class
SmtpMail.Send(objMM)
panelSendEmail.Visible = false
panelMailSent.Visible = true
End Sub

"Mark Rae" <ma**@markNOSPAMrae.netwrote in message
news:uR**************@TK2MSFTNGP06.phx.gbl...
"dancer" <da****@microsoft.comwrote in message
news:O0**************@TK2MSFTNGP04.phx.gbl...
>Then why do I not get new lines with this code?

Because vbCrLf isn't HTML... :-)

Use <br /instead.
--
http://www.markrae.net

May 9 '07 #10
re:
!You will notice that this is VB, not HTML.

Actually, it *is* HTML.

Maybe you missed this line :

'send in html format

What you are doing in that code is *composing HTML*.

Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message news:Oe****************@TK2MSFTNGP02.phx.gbl...
>I am confused.

You will notice that this is VB, not HTML. What do I use so that Location.Text and Check1.Text
and Check2.Text will be on a new line when they appear in the e-mail?

<script language="VB" runat="server">
Sub btnSendFeedback_Click(sender as Object, e as EventArgs)

'Create an instance of the MailMessage class
Dim objMM as New MailMessage()

'Set the properties - send the email to the person who filled out the
'feedback form.
objMM.To = xx****@xxxxxx.com

objMM.From = "xx******@xxxxxxxx.com"
'send in html format
objMM.BodyFormat = MailFormat.Html
'Set the priority - options are High, Low, and Normal
objMM.Priority = MailPriority.Normal

'Set the subject
objMM.Subject = "Accident Investigation Form"

'Set the body
objMM.Body = DateTime.Now + " " & _
Location.Text & _
vbCrLf & vbCrLf & _
Check1.Text & "." & vbCrLf & vbCrLf & _
vbCrLf &vbCrLf & _
Check2.Text & vbCrLf

'Specify to use the default Smtp Server
SmtpMail.SmtpServer = ""
'Now, to send the message, use the Send method of the SmtpMail class
SmtpMail.Send(objMM)
panelSendEmail.Visible = false
panelMailSent.Visible = true
End Sub

"Mark Rae" <ma**@markNOSPAMrae.netwrote in message news:uR**************@TK2MSFTNGP06.phx.gbl...
>"dancer" <da****@microsoft.comwrote in message news:O0**************@TK2MSFTNGP04.phx.gbl...
>>Then why do I not get new lines with this code?

Because vbCrLf isn't HTML... :-)

Use <br /instead.
--
http://www.markrae.net


May 9 '07 #11
THANK YOU VERY MUCH. I'm so glad to get that cleared up!!
"Juan T. Llibre" <no***********@nowhere.comwrote in message
news:%2******************@TK2MSFTNGP03.phx.gbl...
Probably because you're writing HTML.

vbCrLf only works within VB.NET code.

If you're writing HTML, use <br:

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an ASP.NET " & _
"Wheeler's Accident Investigation Form" & "<br>" & Check1.Text & "." &
"<br>" & Check2.Text & "<br>"


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message
news:O0**************@TK2MSFTNGP04.phx.gbl...
>Then why do I not get new lines with this code?

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an ASP.NET "
& _
"Wheeler's Accident Investigation Form" & _
vbCrLf &vbCrLf & _
Check1.Text & "." & vbCrLf & vbCrLf & _
vbCrLf &vbCrLf & _
Check2.Text & vbCrLf

"Juan T. Llibre" <no***********@nowhere.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
>>vbCrLf = Visual Basic Carriage Return Line Feed.


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message
news:us**************@TK2MSFTNGP03.phx.gbl...
What is this? vbCrLf



May 9 '07 #12
Boy, I am too! Was getting a little worried there. :-)
--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net


"dancer" wrote:
THANK YOU VERY MUCH. I'm so glad to get that cleared up!!
"Juan T. Llibre" <no***********@nowhere.comwrote in message
news:%2******************@TK2MSFTNGP03.phx.gbl...
Probably because you're writing HTML.

vbCrLf only works within VB.NET code.

If you're writing HTML, use <br:

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an ASP.NET " & _
"Wheeler's Accident Investigation Form" & "<br>" & Check1.Text & "." &
"<br>" & Check2.Text & "<br>"


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message
news:O0**************@TK2MSFTNGP04.phx.gbl...
Then why do I not get new lines with this code?

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an ASP.NET "
& _
"Wheeler's Accident Investigation Form" & _
vbCrLf &vbCrLf & _
Check1.Text & "." & vbCrLf & vbCrLf & _
vbCrLf &vbCrLf & _
Check2.Text & vbCrLf

"Juan T. Llibre" <no***********@nowhere.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
vbCrLf = Visual Basic Carriage Return Line Feed.


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message
news:us**************@TK2MSFTNGP03.phx.gbl...
What is this? vbCrLf




May 9 '07 #13
ROFLMAO

:-D

--
Best regards,
Dave Colliver.
http://www.AshfieldFOCUS.com
~~
http://www.FOCUSPortals.com - Local franchises available
"Peter Bromberg [C# MVP]" <pb*******@yahoo.yabbadabbadoo.comwrote in
message news:A3**********************************@microsof t.com...
Boy, I am too! Was getting a little worried there. :-)
--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net


"dancer" wrote:
>THANK YOU VERY MUCH. I'm so glad to get that cleared up!!
"Juan T. Llibre" <no***********@nowhere.comwrote in message
news:%2******************@TK2MSFTNGP03.phx.gbl. ..
Probably because you're writing HTML.

vbCrLf only works within VB.NET code.

If you're writing HTML, use <br:

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an ASP.NET " & _
"Wheeler's Accident Investigation Form" & "<br>" & Check1.Text & "." &
"<br>" & Check2.Text & "<br>"


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message
news:O0**************@TK2MSFTNGP04.phx.gbl...
Then why do I not get new lines with this code?

'Set the body
objMM.Body = DateTime.Now + " feedback was sent from an
ASP.NET "
& _
"Wheeler's Accident Investigation Form" & _
vbCrLf &vbCrLf & _
Check1.Text & "." & vbCrLf & vbCrLf & _
vbCrLf &vbCrLf & _
Check2.Text & vbCrLf

"Juan T. Llibre" <no***********@nowhere.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
vbCrLf = Visual Basic Carriage Return Line Feed.


Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"dancer" <da****@microsoft.comwrote in message
news:us**************@TK2MSFTNGP03.phx.gbl...
What is this? vbCrLf





May 9 '07 #14
"Peter Bromberg [C# MVP]" <pb*******@yahoo.yabbadabbadoo.comwrote in
message news:A3**********************************@microsof t.com...
Boy, I am too! Was getting a little worried there. :-)
I was getting ready to sell my flat and head for the hills...
--
http://www.markrae.net

May 9 '07 #15

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Jason | last post by:
When users fill out my text area field, there is a chance that there will be no line feeds or cariage returns or spaces and just one really long word. THIS CAUSES A MAJOR PROBLEM! What I am trying...
2
by: Techy | last post by:
I have used thecode which is below to get x characters on to display <%= LEFT(rsName.Fields.Item("columnname").Value,50)%> It works fine but when I use this same code to get x characters plus...
1
by: techy techno | last post by:
I have used thecode which is below to get x characters on to display <%= LEFT(rsName.Fields.Item("columnname").Value,50)%> It works fine but when I use this same code to get x characters plus...
6
by: Michael.McD | last post by:
Would anyone know how I might access to the vbCrLf constant. I'd like to use teh following bit of VB code in C#: strFoo.Text.Replace(vbCrLf, chr(10) ) Thanks in advance, Michael McD Ps...
0
by: Joe | last post by:
Hi, I have a simple form that does nothing but emails the whatever user entered in the form fields. The form is working fine and email sent. The problem I am having is in te string that forms...
4
by: Andyza | last post by:
I'm using FileSystemObject to open and write to a tab delimited text file. First, I connect to a database and select some data. Then I create the text file and insert each record in the text...
0
by: Jim in Arizona | last post by:
Is there an easier way to make a datalist aware of line breaks within text fields? I have a text box that users can type into. If they press the enter key a few times, VB sees this as a vbCrLf....
3
by: wildman | last post by:
Is there any way for gridview cells to observe vbcrlf in the data? I attempted to do this, but it does not seem to work. Dim dgItem As GridViewRow For Each dgItem In gridCollaborator.Rows...
1
by: Jim in Arizona | last post by:
On one page I have a datalist where a message is bound to a label. On another page I have the datalist which allows for the insert of new message as well as being able to edit those messages. The...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.