• 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
Messing with the dock.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Messing with the dock.


  • Subject: Messing with the dock.
  • From: email@hidden
  • Date: Thu, 9 Sep 2010 09:44:53 -0500

Good Morning,

I am trying to develop a script that will place a application located in the /Applications folder into the dock, for this example I used Stickies. I found this script on the web but it launches the Application before it places itself in the Dock and I would rather that not happen. Any help would be much appreciated!


tell application "Stickies" to launch
tell application "System Events" to tell UI element "Stickies" of list 1 of process "Dock"
        perform action "AXShowMenu"
        click menu item "Options" of menu 1
        tell menu item "Keep in Dock" of menu 1 of menu item "Options" of menu 1
                if not (value of attribute "AXMenuItemMarkChar" exists) then
                        click
                else
                        key code 53 -- escape
                end if
        end tell
end tell


Jeff Madson/RR Donnelley/email@hidden




 _______________________________________________
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: Messing with the dock.
      • From: Luther Fuller <email@hidden>
    • Re: Messing with the dock.
      • From: Luther Fuller <email@hidden>
  • Prev by Date: Re: Accessing Gmail Mailboxes (folders?)
  • Next by Date: Re: Messing with the dock.
  • Previous by thread: Re: Accessing Gmail Mailboxes (folders?)
  • Next by thread: Re: Messing with the dock.
  • Index(es):
    • Date
    • Thread