• 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: Why put all handlers at the top of the script?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Why put all handlers at the top of the script?


  • Subject: Re: Why put all handlers at the top of the script?
  • From: Deivy Petrescu <email@hidden>
  • Date: Fri, 20 Mar 2015 15:24:28 -0400

> On Mar 20, 2015, at 10:46 , S. J. Cunningham <email@hidden> wrote:
>
> I'm guessing it makes it a little faster to compile but I have the time.  In fact,  I probably waste more time than I save by having to scroll to the bottom of the script every time I want to edit it.  Is there any compelling reason for this practice?
> _______________________________________________

Script Editor compiles the script before execution, therefore you can put the handler wherever you want.
If you use Smile’s Terminal, compilation is done at the run time, if you declare a script at the bottom, it will not be used in the code, any call to it will result in error.

So, for SE no mandatory positioning of the handler in Smile’s terminal it must be at the top.

Deivy Petrescu
email@hidden




 _______________________________________________
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: Why put all handlers at the top of the script?
      • From: Christopher Stone <email@hidden>
References: 
 >Why put all handlers at the top of the script? (From: "S. J. Cunningham" <email@hidden>)

  • Prev by Date: Re: Why put all handlers at the top of the script?
  • Next by Date: Re: Why put all handlers at the top of the script?
  • Previous by thread: Re: Why put all handlers at the top of the script?
  • Next by thread: Re: Why put all handlers at the top of the script?
  • Index(es):
    • Date
    • Thread