Is it possible to invoke a keyboard shortcut from applescript?
For example I like to run the F11 keyboard shortcut.
Is it possible to invoke a keyboard shortcut from applescript?
For example I like to run the F11 keyboard shortcut.
Do you mean open the applescript from keyboard shortcut? if so, then follow this to convert the applescript into an app, then create a Service using Automator.
Hope this helps.
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.