• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Newbie, every word where it contains "ox"
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Newbie, every word where it contains "ox"


  • Subject: Re: Newbie, every word where it contains "ox"
  • From: Rob Stott <email@hidden>
  • Date: Thu, 08 Aug 2002 12:41:37 +0100

Hi Steen,

There may be a better way of doing it, but here's how I'd deal with the
problem, hope its of some help;



set myString to "the fox oxon can count 1 2 3 and he love nox"
set theNumberOfTheWords to the count of the words of myString

repeat with theWordNumber from 1 to theNumberOfTheWords
set theWord to word theWordNumber of myString
set theOffset to offset of "ox" in theWord
if theOffset is 0 then
display dialog "Word " & theWordNumber & " does not contain the
string you're looking for"
else
display dialog "SUCCESS! Word " & theWordNumber & " does contain the
string you're looking for"
beep
end if
end repeat


--

Rob Stott
Artwork Designer
Airfix/Humbrol Ltd
Marfleet
Kingston upon Hull
HU9 5NE

Tel: +44 (0) 1482 716691
Fax: +44 (0) 1482 781781
Mob: +44 (0) 7881 811533

'Y'know... For kids!" - Norville Barnes
_______________________________________________
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.

References: 
 >Newbie, every word where it contains "ox" (From: Steen <email@hidden>)

  • Prev by Date: A question about LN Softwares XML Tools
  • Next by Date: Re: Newbie, every word where it contains "ox"
  • Previous by thread: Newbie, every word where it contains "ox"
  • Next by thread: Re: Newbie, every word where it contains "ox"
  • Index(es):
    • Date
    • Thread