var AE = Application ( "Adobe After Effects CC 2014" ) ; AE . activate ( ) ; delay ( 1 ) ; sys = Application ( "System Events" ) ; sys . keystroke ( "n" , { using : "command down" } ) ; sys . keystroke ( "Main Comp" ) ; sys . keyCode ( 36 ) ; sys . keyCode ( 36 ) ;