• 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: How to prevent Classic from starting?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to prevent Classic from starting?


  • Subject: Re: How to prevent Classic from starting?
  • From: Walter Ian Kaye <email@hidden>
  • Date: Thu, 18 Dec 2003 15:41:55 -0800

At 02:26a -0600 12/18/2003, Jeffrey Mattox didst inscribe upon an electronic papyrus:

I can do this to get it to compile without errors:

tell application theApp
using terms from application "Keychain Scripting"
name of current keychain
end
end tell

But am I still risking Classic loading at run time or, worse, a dialog box asking the user to locate the Keychain Scripting application?

Nope; found this on Apple's Russia site:

You can nest Tell and Using Terms From blocks within each other.
If the Using Terms From block is within a Tell block, AppleScript
uses terms from the target specified by the Tell block.

So the nesting you have there is ideal.


At 03:46a -0600 12/18/2003, Jeffrey Mattox didst inscribe upon an electronic papyrus:

At 8:53 PM -0800 12/17/03, Walter Ian Kaye wrote:
Or just launch the right app beforehand:

tell app "Finder"
open application file id "com.apple.keychainscripting"
end tell

tell app "Keychain Scripting"
count keychains
end tell

-boo

That works sometimes, but not always. If I put a delay 4 in between the two tell blocks, it seems to help, but the uncertainty is unsettling. And without the delay I've seen this error "Keychain Scripting got an error: Application isn't running."

OK, then let's combine the methods, and use Finder to get the path:

tell app "Finder"
set kcs_path to application file id "com.apple.keychainscripting" as string
end tell

tell app kcs_path
using terms from application "Keychain Scripting"
name of current keychain
end using terms from
end tell


-boo
hoping that disabling PureVoice will stop his Eudora from crashing
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: How to prevent Classic from starting?
      • From: Paul Berkowitz <email@hidden>
References: 
 >Re: How to prevent Classic from starting? (From: Paul Berkowitz <email@hidden>)
 >Re: How to prevent Classic from starting? (From: Jeffrey Mattox <email@hidden>)
 >Re: How to prevent Classic from starting? (From: Graff <email@hidden>)
 >Re: How to prevent Classic from starting? (From: Jeffrey Mattox <email@hidden>)

  • Prev by Date: set selection to clipboard
  • Next by Date: Re: Chack keys pressed
  • Previous by thread: Re: How to prevent Classic from starting?
  • Next by thread: Re: How to prevent Classic from starting?
  • Index(es):
    • Date
    • Thread