• 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: Help with find text command
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Help with find text command


  • Subject: Re: Help with find text command
  • From: Philip Aker <email@hidden>
  • Date: Thu, 02 Aug 2007 12:41:07 -0700

On 2007-08-02, at 10:28:08, has wrote:

-- find 13-character substrings that may be an ISBN
set possMatches to find text "\\<[[:digit:]][[:digit:]-]{11} [[:digit:]X]\\>" in theText with regexp and all occurrences

Additional testing uncovers a subtle problem with this pattern - the word boundary patterns (\< and \>) consider hyphens as boundaries, so something like "979-0-123-45678-X" would match as "0-123-45678-X" which you don't want it to.

Good catch Hamish,

Here's some other comments: <http://regexadvice.com/blogs/dneimke/ archive/2003/12/06/179.aspx>




Philip Aker email@hidden


_______________________________________________ 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
References: 
 >Re: Help with find text command (From: has <email@hidden>)
 >Re: Help with find text command (From: has <email@hidden>)
 >Re: Help with find text command (From: has <email@hidden>)

  • Prev by Date: Re: Help with find text command
  • Next by Date: Mail not triggering rule script?
  • Previous by thread: Re: Help with find text command
  • Next by thread: Re: Help with find text command
  • Index(es):
    • Date
    • Thread