Re: parsing a large text file
Re: parsing a large text file
- Subject: Re: parsing a large text file
- From: email@hidden
- Date: Mon, 10 Jul 2006 08:05:06 -0600
Thanks for the input.
I ended up using:
--
set theFile to choose file with prompt "Please select the file to read
from..."
set inFile to open for access theFile
set theFile to choose file name with prompt "Save transformed data..."
set outFile to open for access theFile with write permission
repeat
try
set dataLine to read inFile until return
on error
close access inFile
close access outFile
return
end try
-- do what you want with the line of data
write dataLine to outFile
end repeat
--
It worked great for the intended purpose.
The file I'm parsing is indeed 32 MB.
Although I'd like to use shell scripting, I feel overwhelmed just
getting AppleScript to work.
Thanks again.
--
DOS
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden