• 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: Repeat-Dialog-Error
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Repeat-Dialog-Error


  • Subject: Re: Repeat-Dialog-Error
  • From: Paul Berkowitz <email@hidden>
  • Date: Wed, 28 Feb 2001 23:17:08 -0800

On 2/28/01 9:13 PM, "Emmanuel" <email@hidden> wrote:

> At 21:28 -0600 28/02/01, Paul Berkowitz wrote:
>> Because "Cancel" is actually an error, error number -128 to be precise. So
>> if if you want a dialog to display an error, but NOT when a user cancels
>> somewhere, you can use that to advantage:
>
> Just in case, be aware that "Cancel" throws the error only in US/English
> systems.

Actually, it does the same thing in English(UK) and English(Australian) as
well. But since my little example said nothing about the "Cancel" button,
but rather about error number -128, it will work if you have a French system
and click the "Annuler" button, etc.

When I put the word "Cancel" as a button in my scripts (as opposed to
specifying no buttons at all, where the localized version of {"Cancel",
"OK"} will arise on its own), I always add

if button returned of result = "Cancel" then
error number -128

for just the reason that Emmanuel states. If the script makes it that far
(if it hasn't canceled the instant that a user clicked "Cancel") it must be
because it's on a non-English language system and will require an enforced
cancel through error number -128.

--
Paul Berkowitz


References: 
 >Re: Repeat-Dialog-Error (From: Emmanuel <email@hidden>)

  • Prev by Date: Re: Where is the Searchable Applescript-users Archive?
  • Next by Date: Re: I want to convert a list of integers to their negative self
  • Previous by thread: Re: Repeat-Dialog-Error
  • Next by thread: Re: Repeat-Dialog-Error
  • Index(es):
    • Date
    • Thread