Breaking up a large text file

RWSny...@gnn.com (Richard W. Snyder)  wrote:

Quote
> I'm writing a program that uses a lot of large text blocks in the various
> forms.  The text blocks need to be easily changed.  I'm using TMemo fields
> to display the text.  I've tried loading the text into the Lines property
> during development and loading the text using LoadFromFile() function into
> Lines at runtime.  I like the LoadFromFile() concept but don't want to have
> nearly one hundred text files littering the application space.  Can I put
> all the text into one file and simply skip to the right area and load the
> text into a TMemo field?  If so, how?  I only have to load the text once
> each time the program is run.

> Thanks in advance for any help.

> V/R,
> Rich

Hi Richard,
I am not quite sure what you need to do.
Do you have one large text file, which you need to split up
into many blocks ? Is the text file larger than a TMemo can hold ?

Or do you have many smaller files (do you know in advance the
filenames ?). If you have a list of filenames, you could store the
filenames in a TStringList, and from that list use Loadfromfile

is that any help ?

regards
Wolfgang

## CrossPoint v3.1 ##