Word and Applescript

Posted:
in Genius Bar edited January 2014
The outline: I have a one hour interview to transcribe. I have an Applescript to rewind the mp3 of the interview by 10 seconds. I want to be able to do this from within Word.



The Task: tell me how to make a keyboard shortcut in Word (I know that bit ) to fire off this Applescript (don't know that bit )



What I don't want: "Switch to iTunes and run the script that way" Futhermore, I'd like to be able to do this without installing some keyboard remapping software, but am willing to do so if that is the only solution!



Any help much appreciated.

Comments

  • Reply 1 of 4
    If you are just transcribing text then I suggest using Tex-Edit Plus. It plays very nicely with AppleScript. You can assign keyboard short cuts to AppleScripts from within Tex-Edit Plus. When you have finished transcribing the document just copy it and paste it into word for formatting and such.



    From the help page:



    To add a keyboard shortcut to a script:

    ? \tFor a command key shortcut, append slash-character to the script's name. ("ScriptName/0")

    ? \tFor a shift-command shortcut, append slash-slash-character. ("ScriptName//0")

    ? \tFor a function key shortcut, append slash-Fkey. ("ScriptName/F5")

    ? \tFor command-Fkey, append slash-slash-Fkey. ("ScriptName//F5")

    ? \tFor shift-command-Fkey, append slash-slash-slash-Fkey. ("ScriptName///F5")



    After renaming the script drop it into the scripts folder in the Tex-Edit Plus folder. You will see lots of other scripts there, some with keyboard shortcuts already appended as examples.



    These are just standard AppleScripts. Though they are in the TE+ folder and are launched by TE+ they are not required to reference TE+ at all.
  • Reply 2 of 4
    low-filow-fi Posts: 357member
    Thanks for the suggestion neutrino. One of the reasons for wanting to do this in word is sheer number of autotexts I already have set up, auto corrects etc.



    I will have at Text-Edit + though.



    But out of sheer curiosity, can the Applescript/Word thing be done?
  • Reply 3 of 4
    I've never worked with word so I don't know about that.



    Here are three alternatives.



    Put the AppleScript on the desktop. Shrink the word window just enough to get access to the AS icon. Double click it when you need to. You will have to click back in the word window to gain focus for word.



    Install the AppleScript icon in the top menu bar. Put your AS the Scripts folder. (Once you install this menu the first option in the menu opens the Scripts folder.) Remove all of the other scripts. Now when you click on the AS icon your script will be at the bottom and relatively easy to reach.



    Get some sort of program like QuickKeys and use it to assign your AS to a function key.
  • Reply 4 of 4
    neutrino23neutrino23 Posts: 1,562member
    On MacOSXhints I found something relevant. Apparently in OS X 10.3 you can create keyboard shortcuts without the help of third party programs.



    "Go to the Keyboard & Mouse Preference Pane and add a keyboard shortcut for all applications for the [compiled applescript application]."





    "Login and logout and voila, arbitrary command run by keyboard!"
Sign In or Register to comment.