• 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: Load Script
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Load Script


  • Subject: Re: Load Script
  • From: Luther Fuller <email@hidden>
  • Date: Sat, 28 May 2011 06:47:20 -0500

On May 28, 2011, at 6:11 AM, Axel Luttgens wrote:

on entryPointHandler(AppName)
(((path to me) as text) & "Contents:Resources:MenuItemScripts:" & AppName & ".scpt") as alias
run (load script the result)
end entryPointHandler

That's a nice improvement to use the AppName in a single entryPointHandler.
The entryPointHandler should also contain a master error catcher, like this ...

on  entryPointHandler()
try
(((path to me) as text) & "Contents:Resources:MenuItemScripts:NameOfSome.scpt") as alias
run (load script the result)
on error errText number errNr
if errNr = -128 then
return
else if errNr = -2700 then
my showInstruction(errText)
else
my showError(errText, errNr)
end if
end try
end entryPointHandler ----------------------------------------------------------

Does it accurately mimic my code? I think you've got it!

 _______________________________________________
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: Load Script
      • From: Axel Luttgens <email@hidden>
References: 
 >Load Script (From: Luther Fuller <email@hidden>)
 >Re: Load Script (From: Stan Cleveland <email@hidden>)
 >Re: Load Script (From: Luther Fuller <email@hidden>)
 >Re: Load Script (From: Alex Zavatone <email@hidden>)
 >Re: Load Script (From: Luther Fuller <email@hidden>)
 >Re: Load Script (From: Ron Hunsinger <email@hidden>)
 >Re: Load Script (From: Luther Fuller <email@hidden>)
 >Re: Load Script (From: Axel Luttgens <email@hidden>)
 >Re: Load Script (From: Luther Fuller <email@hidden>)
 >Re: Load Script (From: Axel Luttgens <email@hidden>)
 >Re: Load Script (From: Luther Fuller <email@hidden>)
 >Re: Load Script (From: Axel Luttgens <email@hidden>)

  • Prev by Date: Re: Load Script
  • Next by Date: Re[2]: Convert an image to a PDF
  • Previous by thread: Re: Load Script
  • Next by thread: Re: Load Script
  • Index(es):
    • Date
    • Thread