Delphi Programming

  1. Home
  2. Computing & Technology
  3. Delphi Programming
photo of Zarko Gajic

Zarko's Delphi Programming Blog

By Zarko Gajic, About.com Guide to Delphi Programming since 1998

Programmatically Remove Line Breaks (#13#10) From a Delphi String

Saturday March 1, 2008
in Delphi TIPS :: If you have a 'large' string, for example coming from a TMemo control, one that includes carriage-return + line-feed combinations you might need to replace the "CRLF" with an empty space...

Read the full article to learn how to Programmatically Remove Line Breaks (#13#10) From a Delphi String.

Related:

Comments

March 3, 2008 at 3:45 am
(1) Rawlyn says:

Wouldn’t this code replace every instance of “CRLF” with an instance of ” ” (double-space)? Perhaps not a perfect solution in all instances?

November 17, 2008 at 12:27 pm
(2) Ian says:

SysUtils…

aValue := StringReplace(StringReplace(aValue, ‘#10′, ‘’, [rfReplaceAll]), ‘#13′, ‘’, [rfReplaceAll]);

Leave a Comment

Line and paragraph breaks are automatic. Some HTML allowed: <a href="" title="">, <b>, <i>, <strike>

Discuss

Community Forum

Explore Delphi Programming

About.com Special Features

Build Your Own Website

Step-by-step advice on how to do everything from choosing a Web host to promoting your content. More >

Connect Your Home Computers

Easy ways to connect two computers for networking purposes. More >

Delphi Programming

  1. Home
  2. Computing & Technology
  3. Delphi Programming

©2009 About.com, a part of The New York Times Company.

All rights reserved.