473,706 Members | 2,545 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Carriage Return / Line feed

Hi,

I want to send an Email using ASP (I know how to to this)
The body of the Email contains several variabels
How do I concat string values and separate them by carriage returns/ Line
feeds?

Any help will be greatly appreciate.

Regards,

Arnoud
Jul 19 '05 #1
6 31321
<Arnoud Oortwijk> wrote in message
news:40******** **************@ news.skynet.be. ..
Hi,

I want to send an Email using ASP (I know how to to this)
The body of the Email contains several variabels
How do I concat string values and separate them by carriage returns/ Line
feeds?


Assuming your ASP code is using VBScript (not JScript), use the vbCrLf
character. For example:

myStr = "This is line 1." & vbCrLf & "This is line 2."

Hope this helps,
Peter Foti
Jul 19 '05 #2
Peter Foti wrote on 01 apr 2004 in
microsoft.publi c.inetserver.as p.general:
<Arnoud Oortwijk> wrote in message
news:40******** **************@ news.skynet.be. ..
Hi,

I want to send an Email using ASP (I know how to to this)
The body of the Email contains several variabels
How do I concat string values and separate them by carriage returns/
Line feeds?


Assuming your ASP code is using VBScript (not JScript), use the vbCrLf
character. For example:

myStr = "This is line 1." & vbCrLf & "This is line 2."


Depending on the requirements of the email component used.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Jul 19 '05 #3
> I want to send an Email using ASP (I know how to to this)
The body of the Email contains several variabels
How do I concat string values and separate them by carriage returns/ Line
feeds?


body = body & "This is line one" & vbCrLf
body = body & "This is line two" & vbCrLf

Is that what you mean?
Jul 19 '05 #4
Excellent thanks all
"Randy Rahbar" <rvrahbar@_JUNK ETY_JUNK_hotmai l.com> wrote in message
news:e5******** ******@TK2MSFTN GP12.phx.gbl...
I want to send an Email using ASP (I know how to to this)
The body of the Email contains several variabels
How do I concat string values and separate them by carriage returns/ Line feeds?


body = body & "This is line one" & vbCrLf
body = body & "This is line two" & vbCrLf

Is that what you mean?

Jul 19 '05 #5
if vbCrLf is specified:

vbCrLf = Chr(13)&Chr(10)
Jul 19 '05 #6
It's a built-in constant and doesn't need to be specified.

--
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/
"Maarten" <no****@pandora .be> wrote in message
news:gW******** *************@p hobos.telenet-ops.be...
if vbCrLf is specified:

vbCrLf = Chr(13)&Chr(10)

Jul 19 '05 #7

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

Similar topics

3
9313
by: Canes_Rock | last post by:
The information posted at: http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&threadm=slrnarv28n.e4j.TuxTrax%40fortress.tuxnet&rnum=1&prev=/groups%3Fq%3Dsuppress%2Bcarriage%2Breturn%2Bgroup:comp.lang.python.*%26hl%3Den%26lr%3D%26ie%3DUTF-8%26group%3Dcomp.lang.python.*%26selm%3Dslrnarv28n.e4j.TuxTrax%2540fortress.tuxnet%26rnum%3D1 seemed to provide a solution to eliminating the line feed and causing a carriage return for the text displayed...
1
850
by: wschaub | last post by:
Is there any way of forcing an ASMX web service not to translate a carriage return – line feed (\r\n) with a (\n\n), in other words the carriage return \r is replaced with a \n if contained as part of a string that is transferred to a web service method. The XML 1.1 standard is supposed to address this problem, however, we are not aware of any plans of ASMX and serializers to implement this standard in the near future.
3
127925
by: David N. | last post by:
Hi All, I spent too much time on trying to get the CrLf into a string, which contains embedded SQL statements that can be executed by the SQLClient.SqlCommand. Note that these SQL statements work fine in VB.Net. Here is a sample of the code using System; namespace MyTest { internal class SqlCommandFile
1
2322
by: Jim Heavey | last post by:
In the Regular Expression, I can use \n for Line Feed, \t for a tab and \r for carriage return. Am I able to use thos same expressions in a "Replace method" of the string object? such as NewDescrp = NewDescrp.Replace('\n', ' '); //replace Line feed with space NewDescrp = NewDescrp.Replace('\t', ' '); //replace vertical tab with space NewDescrp = NewDescrp.Replace('\r', ' '); //replace Carriage return with a space
2
2336
by: Matt Mercer | last post by:
Hi all, I am having a frustration problem, and I have read about 25 newsgroup postings that do not have a satisfying answer :) The problem appears to be common where carriage returns are lost when pulling data from an SQL database. The thing that frustrates me the most, is that when I use Enterprise Manager, the carriage returns ARE THERE. It looks fine until I pull it out.
2
2335
by: sys | last post by:
I have a web method that returns a string. When I return a string that has a carriage return and line feed in it ("\r\n") on the client side I only receive a string including the line feed ("\n"). The carriage return disappeared. Thanks for any help.
11
8460
by: TheRain | last post by:
Hi, I am trying to append a carriage return to my string using the string builder class, but when I do this the string ends up containing "13". I tried this multiple ways like so sb->Append('\r'); and also
3
10015
by: Gillian Steele | last post by:
I'm trying to import data into a memo field by running an append query. The data is to be imported as if it was entered with separate lines in the memo field. I have tried inserting chr(13)s into the string that is being appended into the memo field but when appended, the data displays with a square box in place of a carriage return/line feed. I would like to import the data so that data is displayed in separate lines within the memo...
4
27824
by: whitej77777 | last post by:
I am trying to write a user defined function that will allow me to strip off the last carriage return and line feed from a text field. We have address fields stored in a text field for our ERP system and some of them have an extra carriage return and line feed at the end of them. This causes havoc when we sync between our ERP system and CRM system. If anyone knows a way to solve this problem the help would be appreciated. Examples:...
4
4698
by: coolguyraj | last post by:
Hi. I have form that has a text box. I want insert unformatted text into the database. Even if the user gives an carriage return or New line feed in the database it should be stored as on single line without any formatting. I just want to remove New Line Feed(\n) Carriage Return(\r) spaces at the begin and end of the string.
0
8773
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8983
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7897
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6613
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5935
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4442
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4705
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3141
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2084
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.