Jump to content

Create a new file with IA Writer PRO

Recommended Posts

  • 2 weeks later...

Yes it is. You can just use osascript from the command line:

osascript -e "activate application \"Pages\"" -e "delay 1" -e "tell application \"System Events\" to keystroke \"n\" using command down" 

That script will open Pages, wait one second, and then send the keystrokes. You can change out "Pages" with the other app names, but make sure that you get them perfect because AppleScript is sensitive. You can remove the delay, but then keystrokes might be sent before the application is open.

Edited by Shawn Rice
Link to comment

Tidied up a little bit:

osascript -e 'activate application "Pages"' -e "delay 1" -e 'tell application "System Events" to keystroke "n" using command down'
Also, you might need to increase the delay for the case that Pages isn't running and your computer is as slow as mine. Edited by deanishe
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...