Re: Why doesn't this cause an error?
Re: Why doesn't this cause an error?
- Subject: Re: Why doesn't this cause an error?
- From: Mr Tea <email@hidden>
- Date: Tue, 24 Sep 2002 09:59:46 +0100
This from Paul Berkowitz - dated 24-9-02 02.06 am:
>
If there's no offset, the offset indeed is 0, so that's the result you get.
>
I'm not sure why you think that's worse than getting an error. You just have
>
to set up an 'if the result = 0 then' condition to deal with it.
Did I say 'worse'? No. Unexpected is not equivalent to worse. I based my
expectations on the notion that AS usually returns an error when you ask it
to find something that isn't there. It seemed likely (to me, at least) that
this would also be the case when asking it to find the offset of something
that isn't there.
If only I'd read Bill Briggs' article on MacCentral (about renaming digital
photos with AS) first, then the zero would have been wholly expected because
that's what Bill says will happen: "Zero is what the command returns when no
match if found".
BTW - Did you get yourself that digital camera yet, Bill?
>
Generally speaking, if you can find some other way of doing something other
>
than 'offset', do the other way.
Because... ?
Regards
N.
_______________________________________________
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.