Problem here most likely is that you are trying to read the entire 300MB file into memory at once. Unless you have an extra 300MB block of RAM floating around, this will start beating on virtual memory pretty hard (and increasingly slow).
You'll notice that your non-MetaCard script reads one line at a time- I would suggest doing the same.
If you are just looking for occurences of a single string, you could also try using the grep command-line tool. Type "man grep" into the Terminal for syntax.
HTH,
Brian
- Read and Analyze Giant Files Sannyasin Sivakatirswami
- Re: Read and Analyze Giant Files andu
- Re: Read and Analyze Giant Files Pierre Sahores
- Yennie