🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #6339

Re: AnsiString and the LineFeed char

#6339
From: Robert G. Hoover
Date: Tue, 17 May 2005 17:20
56 lines
2365 bytes
Ok, so if I write:

MyTMemo->Lines->Text = "1\n2\n3\n4\n5";

...then I get...

1
2
3
4
5

... just as you said. But, if I write (to simulate my incoming hint)...

Application->Hint = "1\n2\n3\n4\n5";
MyTMemo->Lines->Text = GetLongHint(Application->Hint);

...I get...

1|2|3|4|

...so is my problem with the GetLongHint()?


Thanks,

Rob




Remy Lebeau (TeamB) wrote:

> "Robert G. Hoover" <not.a.real.address@anywhere.sorry> wrote in message
> news:428a086f$1@newsgroups.borland.com...
> 
> 
>>If I'm using a TMemo, then the '\n' is not interpreted as a EOL
>>char, but rather it is displayed as \n.
> 
> 
> That is not correct. "\n" is indeed treated as EOL.
> 
> 
>>For example, I'd like to send an AnsiString like the following....
>>
>>AnsiString TextString = "1. Go to start.\n2. Walk north, 3 steps.\n3.
>>Walk east, 5 steps.\n4. Dig up treasure.";
> 
> 
> That works just fine.  The \n characters are indeed treated as EOL.
> 
> 
> Gambit
> 
> 
Technical Details
Message-ID: <428a27e9@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!diablo.voicenet.com!news-out.newsgroups.com!propagator2-sterling.newsfeeds.com!news-in.nuthinbutnews.com!news-in.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail
References: <42826ce0@newsgroups.borland.com> <428279f7$1@newsgroups.borland.com> <428a086f$1@newsgroups.borland.com> <428a1a01@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,617c7c48d8598286
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
Date: Tue, 17 May 2005 13:20:39 -0400
From: "Robert G. Hoover" <not.a.real.address@anywhere.sorry>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.7) Gecko/20050414
X-Accept-Language: en-us, en
MIME-Version: 1.0
Newsgroups: borland.public.cppbuilder.nativeapi
Subject: Re: AnsiString and the LineFeed char
References: <42826ce0@newsgroups.borland.com> <428279f7$1@newsgroups.borland.com> <428a086f$1@newsgroups.borland.com> <428a1a01@newsgroups.borland.com>
In-Reply-To: <428a1a01@newsgroups.borland.com>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
X-Antivirus: avast! (VPS 0520-1, 05/17/2005), Outbound message
X-Antivirus-Status: Not-Tested
NNTP-Posting-Host: 68.48.159.204
Message-ID: <428a27e9@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1116350441 68.48.159.204 (17 May 2005 10:20:41 -0700)
Lines: 56
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!diablo.voicenet.com!news-out.newsgroups.com!propagator2-sterling.newsfeeds.com!news-in.nuthinbutnews.com!news-in.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail