• 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: [Off list] Re: string count in log file
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Off list] Re: string count in log file


  • Subject: Re: [Off list] Re: string count in log file
  • From: Greg Sutherland <email@hidden>
  • Date: Mon, 24 Sep 2001 18:04:08 -0400 (EDT)

THANK YOU Nigel!!!!
I changed
"set AppleScript's text item delimiters to srchStrng" to
"set AppleScript's text item delimiters to srchStrng's contents"
and IT WORKS!!!

greg

On Mon, 24 Sep 2001, Nigel Garvey wrote:

> Date: Mon, 24 Sep 2001 17:20:37 +0100
> From: Nigel Garvey <email@hidden>
> To: Greg Sutherland <email@hidden>
> Subject: [Off list] Re: string count in log file
>
> Greg Sutherland wrote on Mon, 24 Sep 2001 10:23:54 -0400 (EDT):
>
> >I downloaded Smile and have been trying to figure out what is happening.
> >When I set srchStrng rather than letting it get set by repeat then the
> >count works. With a display dialog in the loop srchStrng looks correct
> >when set by repeat, but the count is always 0.
>
> Hi, Greg.
>
> I replied to your original query a few days ago. Maybe you missed it. (Or
> maybe it doesn't work for you as it did for me. :-( ) Anyway, here's my
> post again in case it's of use.
>
> Best wishes,
> Nigel
>
> ----------
> >set od to AppleScript's text item delimiters
> >repeat with srchStrng in srchTbl
> > set AppleScript's text item delimiters to srchStrng
>
> srchStrng is a reference in this kind of repeat, not a string, so you're
> setting the delimiters to the reference rather than the string to which
> it refers. The 'text items of theText' is therefore a list containing
> just one item (the whole of 'theText'), so the count - 1 is 0. You need
> either to get the 'contents' of the reference:
>
> set AppleScript's text item delimiters to srchStrng's contents
>
> ... or to do a pretend coercion:
>
> set AppleScript's text item delimiters to srchStrng as string
>
> or:
>
> set AppleScript's text item delimiters to srchStrng as item


  • Prev by Date: RE: AS adoption barriers
  • Next by Date: Re: Command execution ala Director's message window
  • Previous by thread: RE: AS adoption barriers
  • Next by thread: RE: AS adoption barriers [Starter Kit]
  • Index(es):
    • Date
    • Thread