Re: AppleScript's text item delimiters have stopped working
Re: AppleScript's text item delimiters have stopped working
- Subject: Re: AppleScript's text item delimiters have stopped working
- From: Tommy Bollman <email@hidden>
- Date: Sun, 4 Jul 2010 14:37:55 +0200
Hello Tom!
You need to address the property where DEFAULT_TID resides, or make sure it is somewhere in your parent chain.
I guess that What has happened, is that the line with set AppleScript's text item delimiters failed because it couldn't resolve DEFAULT_TID.
Hopes this helps, and it would still be very nice to see Hirhotos original code with handlers - he is good! So please...
and thanks and hopes this helps.
On 4. juli 2010, at 13.07, tom wible wrote:
> i have a top-level handler:
>
> to extractValFrom(txt, delim)
> log "extractValFromDelim(" & delim & ")"
> set AppleScript's text item delimiters to {delim}
> set val to item 2 of txt
> set AppleScript's text item delimiters to DEFAULT_TID -- previously set
> log "extractValFrom(" & txt & ")=" & val & "="
> return val
> end extractValFrom
>
> which i call thusly:
>
> extractValFrom("run longer =30", "=")
>
> and there's what i get:
>
> (*extractValFromDelim(=)*)
> (*extractValFrom(run longer =30)=u=*)
>
> this used to work, until i implemented s.o. constructors:-(
>
Best regards
Tommy Bollman
--------------------------------------------------------------------------------------------------
Mollison's Bureaucracy Hypothesis:
If an idea can survive a bureaucratic review
and be implemented it wasn't worth doing.
_______________________________________________
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