Is it possible to invoke a keyboard shortcut from applescript?
For example I like to run the F11 keyboard shortcut.
Ask Different is a question and answer site for power users of Apple hardware and software. It only takes a minute to sign up.Sign up to join this community
The following works from the terminal.
osascript -e "tell applications \"System Events\"" -e "key code 100" -e "end tell"
Alternatively I believe this should work.
tell application "System Events" key code 101 end tell
Googling mac osx system events key code should bring up several options.