• 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
Applescript in the terminal (fwd)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Applescript in the terminal (fwd)


  • Subject: Applescript in the terminal (fwd)
  • From: - <email@hidden>
  • Date: Wed, 17 Apr 2013 20:15:48 -0400 (EDT)


Hello,

I'm new to the list and to applescript. I do a great deal of my computer use in the terminal of my mac. I discovered one can use a command to evoke applescript. Here is the example I use to control the system audio volume:

osascript -e "set Volume 2"

The number is the relative volume level, 0 is silence. I set a function with the above to easily change it in the terminal.

Often when using a gui application in the bg I want to send a keystroke, or combination, to the open application from within the terminal along the lines of the above.

Is there an applescript command, or set of them, to send keystrokes in this manner? Let us say for example to send the application the "k" keystroke.

Thanks,

Dan

XB
_______________________________________________
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: Applescript in the terminal (fwd)
      • From: Alex Zavatone <email@hidden>
    • Re: Applescript in the terminal (fwd)
      • From: John Day <email@hidden>
  • Prev by Date: Re: Re(2): PowerMail: Sending and CCing to Messrs Foo & Bar
  • Next by Date: Re: Applescript in the terminal (fwd)
  • Previous by thread: Re: Re(2): PowerMail: Sending and CCing to Messrs Foo & Bar
  • Next by thread: Re: Applescript in the terminal (fwd)
  • Index(es):
    • Date
    • Thread