• 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
Fwd: detect return, expanded
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Fwd: detect return, expanded


  • Subject: Fwd: detect return, expanded
  • From: KOENIG Yvan <email@hidden>
  • Date: Sat, 05 Nov 2011 17:13:03 +0100



Début du message réexpédié :

set theColorList to {"0-none", "1-orange", "2-red", "3-yellow", "4-blue", "5-purple", "6-green", "7-gray"}
set theDefaultChoice to "0-none"

repeat while not return
set theChoice to choose from list theColorList default items theDefaultChoice with title "Color"
delay 0.5
end repeat



Maybe this one may help :
set theColorList to {"0-none", "1-orange", "2-red", "3-yellow", "4-blue", "5-purple", "6-green", "7-gray"}
set theDefaultChoice to "0-none"
set theChoice to {}
repeat while theChoice is {}
set theChoice to choose from list theColorList default items theDefaultChoice with title "Color"
end repeat

but in fact I don't understand your problem.

Given the bare script :

set theColorList to {"0-none", "1-orange", "2-red", "3-yellow", "4-blue", "5-purple", "6-green", "7-gray"}
set theDefaultChoice to "0-none"
-- point #1
set theChoice to choose from list theColorList default items theDefaultChoice with title "Color"
-- point #2

If you press escape, you will exit silently
If you wait too much, you will get an error message claiming that the waited event took too much time to apply.
You will reach the point #2 only if you press return.

Yvan KOENIG (VALLAURIS, France) samedi 5 novembre 2011 17:12:58


 _______________________________________________
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

  • Follow-Ups:
    • Re: detect return, expanded
      • From: Robert Poland <email@hidden>
    • Re: detect return, expanded
      • From: wayne melrose <email@hidden>
References: 
 >detect return, expanded (From: Robert Poland <email@hidden>)

  • Prev by Date: detect return, expanded
  • Next by Date: Re: detect return, expanded
  • Previous by thread: detect return, expanded
  • Next by thread: Re: detect return, expanded
  • Index(es):
    • Date
    • Thread