• 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: Simple question - how2 launch apps in OS X via a script
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Simple question - how2 launch apps in OS X via a script


  • Subject: Re: Simple question - how2 launch apps in OS X via a script
  • From: Walter Ian Kaye <email@hidden>
  • Date: Tue, 21 Oct 2003 19:00:37 -0700

At 05:43p -0700 10/21/2003, Robert DeLaurentis didst inscribe upon an electronic papyrus:

Hi list,

What is the best way to launch applications via Applescript. I want to open
a set of apps, some of which are not scriptable. Is there a uniform,
generally accepted method for launching an app itself from a script?

To launch apps that are not scriptable, you can use the Finder.
Try this:

set app_codes to {"ttxt", "CARO", "com.apple.safari"}
tell app "Finder"
repeat with app_code in app_codes
open application file id app_code
end repeat
end tell

You can use either the 4-char creator code, or, if you've got an app which lacks one, the bundle identifier (found in the info.plist in the .app package).


-Walter
_______________________________________________
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.

References: 
 >Simple question - how2 launch apps in OS X via a script (From: Robert DeLaurentis <email@hidden>)

  • Prev by Date: Re: Finder scripting dies
  • Next by Date: Re: Finder scripting dies
  • Previous by thread: Simple question - how2 launch apps in OS X via a script
  • Next by thread: Re: Simple question - how2 launch apps in OS X via a script
  • Index(es):
    • Date
    • Thread