• 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: 'Hierarchy' of libs?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 'Hierarchy' of libs?


  • Subject: Re: 'Hierarchy' of libs?
  • From: Bill Cheeseman <email@hidden>
  • Date: Wed, 07 Feb 2001 06:22:27 -0500

on 2/7/01 5:29 AM, Serge Belleudy-d'Espinose at email@hidden wrote:

> Given:
>
> my_handler() is a handler of the compiled script my_lib1
>
> my_lib2 is a compiled script that begins with
>
> property parent: load script file "my_lib1"
>
> my_script is a script that begins with
>
> property parent: load script file "my_lib2"
>
> I've tried to use my_lib1's my_handler inside my_script, without success. Is
> it possible anyway, with different techniques?

Take a look at this tip at The AppleScript Sourcebook:

<http://www.AppleScriptSourcebook.com/tips/scriptserver.html>

It doesn't address your issue straight on, but I suspect it will work for
you. The trick has to do with enclosing the entire body of "my_lib1" within
an explicit script object. Then "my_lib2" would refer to the script object
of the script file, instead of just referring to the script file. I'm not
sure why this works, but I surmise it has something to do with providing an
execution context.

-
Bill Cheeseman, Quechee, Vermont <mailto:email@hidden>

The AppleScript Sourcebook
<http://www.AppleScriptSourcebook.com/>
Vermont Recipes-A Cocoa Cookbook
<http://www.stepwise.com/Articles/VermontRecipes/>


  • Follow-Ups:
    • Re: 'Hierarchy' of libs? (solved!)
      • From: "Serge Belleudy-d'Espinose" <email@hidden>
References: 
 >'Hierarchy' of libs? (From: "Serge Belleudy-d'Espinose" <email@hidden>)

  • Prev by Date: 'Hierarchy' of libs?
  • Next by Date: Re: Scripting Eudora
  • Previous by thread: 'Hierarchy' of libs?
  • Next by thread: Re: 'Hierarchy' of libs? (solved!)
  • Index(es):
    • Date
    • Thread