• 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: Passing a Handler at Runtime
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Passing a Handler at Runtime


  • Subject: Re: Passing a Handler at Runtime
  • From: Shane Stanley <email@hidden>
  • Date: Wed, 14 Sep 2011 08:52:51 +1000

On Sep 14, 2011, at 7:40 AM, Rick Gordon wrote:
>
> It would preclude the possibility of drawing from multi-handler libraries, though.

You could always have an identically named handler in each script that took the name of the required handler as an argument, and did the calling. Something like:

on callHandler(aName)
if aName = "sliceAndDice" then
my sliceandDice()
...

--
Shane Stanley <email@hidden>
'AppleScriptObjC Explored' <www.macosxautomation.com/applescript/apps/>

 _______________________________________________
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: Passing a Handler at Runtime
      • From: Alex Zavatone <email@hidden>
References: 
 >Re: Passing a Handler at Runtime (From: Rick Gordon <email@hidden>)

  • Prev by Date: Re: entire contents
  • Next by Date: Re: Passing a Handler at Runtime
  • Previous by thread: Re: Passing a Handler at Runtime
  • Next by thread: Re: Passing a Handler at Runtime
  • Index(es):
    • Date
    • Thread