• 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: Help with droplet
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Help with droplet


  • Subject: Re: Help with droplet
  • From: kai <email@hidden>
  • Date: Tue, 3 May 2005 23:09:58 +0100


On Tuesday, May 3, 2005, at 02:05 pm, Emmett Gray wrote:

Thanks so much for your help, kai. I now understand how to do this.

I wonder if you or anyone could answer one further question: I am concerned about the possibility that the firstRun and jobQueue properties you propose could be messed up by a force quit or crash, such that their state is saved as false and not null respectively. Can this happen? I tried to make it happen in testing but did not succeed, so it would appear that properties are not saved in an interrupted run and I need not worry. Are properties persistent (i.e. written to disk) only on a normal quit of an applet? Since my process involves potentially overwriting files, I need to be absolutely sure of this behavior.

I find myself somewhat at odds with the ASLG on this one, Emmett - since it appears to suggest that forcing a quit saves changes to script properties and quits immediately (bypassing the script's quit handler):


http://developer.apple.com/documentation/AppleScript/Conceptual/ AppleScriptLangGuide/AppleScript.e8.html

However, things seem to have changed since this was written (including, of course, the method of forcing an application to quit).

I've carried out some pretty comprehensive tests here in OS 9.1, OS 9.2 (Classic) and OS X. They all indicate that a script application's properties are saved only on completion of execution, when a regular quit occurs - and not when a running script is prematurely interrupted by either a forced quit or a crash.

It seems to me that this behaviour is generally desirable - since it means that if the execution of a script is unexpectedly curtailed, partial/temporary changes to properties will not be saved. Their values will remain as they were before the script was run. And in more normal circumstances, when the script concludes as it should, the original property values will be restored by the relevant handlers anyway.

---
kai

_______________________________________________
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


  • Follow-Ups:
    • Re: Help with droplet
      • From: Jon Pugh <email@hidden>
References: 
 >Re: Help with droplet (From: Emmett Gray <email@hidden>)

  • Prev by Date: Re: every file in path error
  • Next by Date: Re: Using AS to logout
  • Previous by thread: Re: Help with droplet
  • Next by thread: Re: Help with droplet
  • Index(es):
    • Date
    • Thread