Re: How do you get a stay-open applet to quit?
Re: How do you get a stay-open applet to quit?
- Subject: Re: How do you get a stay-open applet to quit?
- From: Adam Bell <email@hidden>
- Date: Sun, 1 Jan 2006 21:07:05 -0400
You want "exit repeat" - the script will quit itself when there's
nothing left to do
On 1/1/06, Michelle Steiner <email@hidden> wrote:
> This didn't work for me:
>
> repeat
> (display dialog "Enter the heart rate or percentage" default answer
> eightyPercent buttons {"Cancel", "Percentage", "Heart rate"} default button
> 3)
> set {TR, BR} to {text returned of the result, button returned of the
> result}
> set NR to TR as number
>
>
> if ((NR is greater than MaxSafe) and (BR is "heart rate")) or ((NR is
> greater than 100) and (BR is "percentage")) then
> set icn to warning
> else
> set icn to informational
> end if
> if BR is "Heart rate" then
> set percentage to ((NR / MaxSafe) * 100) as integer
> display alert "Your heart rate was " & (percentage as text) & "% of the
> Maximum safe heart rate." as icn
> else if BR is "Percentage" then
> set heart_rate to (MaxSafe * NR) / 100 as integer
> display alert "Your heart rate was " & (heart_rate as text) & " beats per
> minute." as icn
> else
> tell me to quit
> end if
> end repeat
>
> -- Michelle
>
> --�
> Prius:� Kicks Gas
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Applescript-users mailing list
> (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
>
>
--
Some minds remain open long enough for a truth to both enter and leave
without processing.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden