Send keystrokes to another app

Is it in any way possible to send keystrokes to another app?
For example, could I quit another app by sending ALT+CMD+Q or copy/paste using CMD+V to another app.

Declares or MBSplugin is accepted. :wink:

With AppleScript it’s “tell application bundleid to quit”. Then there is the shell. You could also use NSProcessInfoMBS.

RemoteControlMBS

I forgotten to add it needs to be sandboxed.
Will try both suggestions.

You may need to ask user to put your apps in list of apps allowed as assistive devices.