• 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: making an app wait for external process
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: making an app wait for external process


  • Subject: Re: making an app wait for external process
  • From: Ron Bishop <email@hidden>
  • Date: Fri, 25 Jul 2003 10:35:25 -0500

I usually have a repeat loop that tests for the existence of an object. It keeps repeating until it returns true; then the script continues.

Example~

tell application "Finder"
set mounted_disks to name of disks
if mounted_disks does not contain "MACSERVE.VOLUME" then open location "afp://.username.starnds:email@hidden/MACSERVE.VOLUME"
repeat until mounted_disks contains "MACSERVE.VOLUME"
set mounted_disks to name of disks
end repeat
--do whatever I'm going to do with that volume...
end tell

Maybe you can have Graphic Converter test for the existence of "document 1" or whatever (I not familiar with scripting GC)

Ron Bishop

On Friday, July 25, 2003, at 10:05 AM, Mania Bug wrote:

I've searched the archives and have not come across anything that looks like the right solution for this... I'm scripting Graphic Converter to acquire an image via twain, and I need my script to wait for the scan to complete before trying to write the file. The delay command won't work because it pauses the whole computer: when it ends, Graphic Converter still isn't ready to accept more instructions and the script dies.

Please send me your favorite strategy for waiting. Thanks!

Jason
_______________________________________________
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.

  • Follow-Ups:
    • Re: making an app wait for external process
      • From: Jason Staloff <email@hidden>
References: 
 >making an app wait for external process (From: Mania Bug <email@hidden>)

  • Prev by Date: System Events - What are they? How do we use them?
  • Next by Date: Re: move theFile to thePath replacing no
  • Previous by thread: making an app wait for external process
  • Next by thread: Re: making an app wait for external process
  • Index(es):
    • Date
    • Thread