RE: Exact word search
RE: Exact word search
- Subject: RE: Exact word search
- From: "Script2" <email@hidden>
- Date: Thu, 18 Sep 2008 09:53:03 -0400
- Importance: Normal
Thanks Mark. This Worked.
-----Original Message-----
From: Mark J. Reed [mailto:email@hidden]
Sent: Thursday, September 18, 2008 9:45 AM
To: Script2
Cc: AS users
Subject: Re: Exact word search
On Thu, Sep 18, 2008 at 9:04 AM, Script2 <email@hidden> wrote:
> If aword contains "FINISH"
>
> Aword is a paragraph.
>
> How do I write this so it searches only upper case FINISH. Above sentence
> returns finishing, finished, Finish................
OK, two separate issues.
1) You want case to matter. Put the test within a "considering case" block.
2) You want only the whole word to match.
Try this:
considering case
if words of aword contain "FINISH" then
...
end if
end considering
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden