Re: scripting bbedit
Re: scripting bbedit
- Subject: Re: scripting bbedit
- From: Jan Erik Moström <email@hidden>
- Date: Wed, 27 Jun 2001 14:21:15 +0200
>
> What is the smartest way to search a big text file an occurance of
>
> specific word and return the number of the line that that word occurs
>
> on?
>
> Is BBEdit the tool to use? Does anyone know if there is a command in
>
> BBEdit's scripting commands that would return this line number?
>
tell application "BBEdit"
set y to find "ab" searching in {text 1 of text window 1} options {search
mode:literal, starting at top:true, returning results:true, showing
results:false}
display dialog "I found " & the number of items of found matches of y & "
items"
end tell
--
Jan Erik Mostrvm
mailto:email@hidden
Free Elektron
http://www.mostrom.pp.se/folk/jem/