• 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 until ...the user chooses to stop?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Repeat until ...the user chooses to stop?


  • Subject: Re: Repeat until ...the user chooses to stop?
  • From: Philip Aker <email@hidden>
  • Date: Wed, 28 Nov 2007 04:54:03 -0800

On 2007-11-27, at 13:22, deivy petrescu wrote:

On Nov 27, 2007, at 14:48, Philip Aker wrote:

On 2007-11-27, at 09:15, Dane Springmeyer wrote:

… applescript does not support sub-second timeouts, so it seems that this approach won't quite work.

That's no longer the case. You can return a fraction of a second. This should illustrate:


on run
	set isot to ((current date) as «class isot») as text
	do shell script "echo '" & isot & "' > ~/Desktop/isot.txt"
end run

on idle
	set isot to ((current date) as «class isot») as text
	do shell script "echo '" & isot & "' >> ~/Desktop/isot.txt"
	return 0.4
end idle

Just to clarify.
Actually I have never said that "applescript does not support sub- second timeouts".
I said that display dialog do not allow for delays less than 1 (try it).

My reply didn't attribute anything to Deivy Petrescu, but yes, I misread the post. Anyway, if the OP is trying to show a modal dialog every 1.5 seconds, that's the wrong approach. He should either use a utility window class in a background AppleScript Studio application or rely on keystrokes alone.



Actually I am not sure if it started with Tiger or with an Tiger upgrade, AS supports delays of less than a second.


I remember Chris Nebel making a remark about it but can't say if it was during the OS X 10.3 or 10.4 era.


Philip Aker echo email@hidden@nl | tr a-z@. p-za-o.@

_______________________________________________
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
References: 
 >Re: Repeat until ...the user chooses to stop? (From: Ron <email@hidden>)
 >Re: Repeat until ...the user chooses to stop? (From: Dane Springmeyer <email@hidden>)
 >Re: Repeat until ...the user chooses to stop? (From: Philip Aker <email@hidden>)
 >Re: Repeat until ...the user chooses to stop? (From: deivy petrescu <email@hidden>)

  • Prev by Date: Re: Imagemagick
  • Next by Date: Re: Can I get return values in xCode?
  • Previous by thread: Re: Repeat until ...the user chooses to stop?
  • Next by thread: Re: Intel, Read/Write, and dates
  • Index(es):
    • Date
    • Thread