• 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: Determining if a scripting addition is installed
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Determining if a scripting addition is installed


  • Subject: Re: Determining if a scripting addition is installed
  • From: Sander Tekelenburg <email@hidden>
  • Date: Fri, 2 Sep 2005 15:58:46 +0200

At 09:22 -0400 UTC, on 2005/09/02, Stephen Jonke wrote:

> Is there any way in applescript to determine if a particular
> scripting addition is loaded? Or more specifically if a particular
> command exists? I'd like to make my script use a scripting addition
> if it is available, but if it isn't then use a workaround.

Sure, just use a try block:

try
	-- routine that requires third-party SA
on error
	-- routine that doesn't require it
end

If you can be sure what error number this would generate, you could make it
more specific:

property ErrNum : <error number>
try
	-- do stuff that requires third-party SA
on error number ErrNum
	-- use routine that doesn't require it
end

thus allowing you to still also catch other specific errors.


--
Sander Tekelenburg, <http://www.euronet.nl/~tekelenb/>
 _______________________________________________
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: Determining if a scripting addition is installed
      • From: Daniel Jalkut <email@hidden>
References: 
 >Determining if a scripting addition is installed (From: Stephen Jonke <email@hidden>)

  • Prev by Date: Re: Translating XML SOAP terms to AppleScript?
  • Next by Date: Re: turn on Remote Apple Events remotely?
  • Previous by thread: Re: Determining if a scripting addition is installed
  • Next by thread: Re: Determining if a scripting addition is installed
  • Index(es):
    • Date
    • Thread