Re: find a string in a file
Re: find a string in a file
- Subject: Re: find a string in a file
- From: Gary Lists <email@hidden>
- Date: Fri, 23 May 2003 21:57:40 -0400
On or about 5/23/03 8:10 PM, Emmanuel wrote:
>
or:
>
>
-------------------------- untested
>
set eFile to alias "EEHD:efile9.txt"
>
set fileText to read eFile
>
>
if offset of "%%" in fileText is 0 then
>
display dialog "Not there."
>
else
>
display dialog "Found"
>
end if
>
---------------------------------
>
>
Emmanuel
As written, this produced the error:
Can't make 0 into a boolean.
Parentheses did the trick (oddly?)
Changing the if... to
(offset of "%%" in fileText)
worked for me. OS9.1.2, AS 1.8.3
--
Gary
Incoming replies are auto-deleted.
Please post directly to the list or newsgroup.
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.