On 2/11/06, Seth Willits <[EMAIL PROTECTED]> wrote:
> If you're reading from a file and appending to a string a lot and
> this string is going to grow pretty large, your application can
> benefit significantly if you preallocate a block of memory and resize
> it only when needed.
Hmm, doesn't this post rather belong onto the Beginner's list? ;)
But while we're at it - when putting together text from single lines,
an easy yet fast way is to collect the lines NOT like this (with the
same explanation that Seth just gave):
do
allText = allText + nextLine () + EndOfLine
loop ...
but like this:
dim individualLines() as String
do
individualLines.Append nextLine ()
loop ...
allText = Join (individualLines, EndOfLine)
Thomas
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>