<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2900.2180" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Hi all</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>I need a fast/efficient way&nbsp;of building a 
string from data within a loop.&nbsp;&nbsp;The string is getting longer and 
longer and therefore reallocating the whole string in memory every loop.&nbsp; 
Each loop it gets&nbsp;a few&nbsp;words added, perhaps an average of&nbsp;30 
bytes.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>I thought of doing a SetLength on the string every 
256 bytes or so, but I'm not sure of the best method of&nbsp;moving&nbsp;the 
data into the correct position&nbsp;in the string.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Any suggestions?</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Cheers,</FONT></DIV>
<DIV><FONT face=Arial size=2>Ross.</FONT></DIV></BODY></HTML>