• 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: NSAppleScript: Compiling a script launches an application
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSAppleScript: Compiling a script launches an application


  • Subject: Re: NSAppleScript: Compiling a script launches an application
  • From: "Matt Deatherage" <email@hidden>
  • Date: Fri, 29 Jul 2005 10:05:15 -0500

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Fri, 29 Jul 2005 16:17:01 +0200, Alexander von Below wrote:

>Unfortunately, the NSAppleScript object does not seem to have the
>ability to save compiled scripts, unless I am overlooking something

a) As noted, you are on the wrong list; that's a Cocoa question, not an
AppleScript question.

b) You're overlooking the -initWithContentsOfURL method that, "Given a
URL that locates a script, in either text or compiled form, initialize
an instance of NSAppleScript."  I suspect you'll wind up saving the
compiled script in your bundle (or in a temporary file) and passing that
URL to this method.

<http://developer.apple.com/documentation/Cocoa/Reference/Foundation/
ObjC_classic/Classes/NSAppleScript.html#//apple_ref/doc/uid/20000697-3357>

[I am not a Cocoa developer, but it does look this easy.]

c) It's working as advertised because any application may need to run to
provide a complete list of its terminology.  You'll find the same thing
with Adobe InDesign and QuarkXPress, for example, because both of them
let plug-ins contribute to scripting terminology.  Until they launch and
enumerate the plug-ins, these applications really don't know what events
they'll accept.

- --
Matt Deatherage                              <email@hidden>
GCSF, Incorporated                      <http://www.macjournals.com>


-----BEGIN PGP SIGNATURE-----
Version: PGP Desktop 9.0.1 (Build 2185)

iQA/AwUBQupFrOQJS+YigHjzEQJM7QCdFsjGF4h6ww0ym3fnZTKwyzM12SwAoPjO
pK5OysaWihF5Tq+G4u2IQdlE
=qT2w
-----END PGP SIGNATURE-----
 _______________________________________________
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

References: 
 >Re: NSAppleScript: Compiling a script launches an application (From: has <email@hidden>)
 >Re: NSAppleScript: Compiling a script launches an application (From: Alexander von Below <email@hidden>)

  • Prev by Date: Re: NSAppleScript: Compiling a script launches an application
  • Next by Date: Re: NSAppleScript: Compiling a script launches an application
  • Previous by thread: Re: NSAppleScript: Compiling a script launches an application
  • Next by thread: unixy paths to alias
  • Index(es):
    • Date
    • Thread