AppleScripts for Macspeech Dictate

OK I’m a major rookie ... But I have MacSpeech dictate and it is lacking any real commands (compared to Dragon 10, it just *****) but I hate using a pc ... So there are no commands available for MS word but in Dictate I can create them using applescript ... Now I managed to create a voice command to open the print window and even one to “press cancel” but I had found a script for that function in another app ... And it had a key code.
tell application "MacSpeech Dictate Medical"
tell process _currentAppName
try
key code 53
end try
end tell
end tell
This actually worked .... I said “press cancel” and it canceled the print window!!! I’m getting somewhere! I would assume that the script would be similar but with a different key code to press the print button ... But I have not found anything that I could copy or even a list of key codes ...
Is there documentation that lists all of the key codes?
Hope you can help
Thanks, Rick

Before you build everything with custom commands, make sure you've looked at what's built into MacSpeech Dictate. The "Global" commands in MacSpeech Dictate will work with any application, including Microsoft Word. These won't do everything you want, but many of them are useful. For example, when you speak "Save This Document" it does the equivalent of Cmd-S on a keyboard. At the very least, many of the pre-configured commands are useful examples (which it looks like you're already using).
Here are some other things to try:
You can also say "Press OK" for the default button (highlighted in blue, for examples "Print") and "Press Cancel" for a "Cancel" button.
For keyboard entry you can say something like "Press The Key Delete" (presses the 'delete' key) or "Press The Key Combo Command Shift Option V" (presses keyboard combo Cmd-Shift-Opt-V, which is 'Paste and Match Style' in some apps). You get the idea from these examples.
Finally, just as you are already doing, you can build and customize your own Voice commands fairly easily. Open up the "Commands" Editor (Tools > Commands). Look through the commands that are pre-configured in MacSpeech Dictate. You'll see examples of commands built with the different methods that Dictate supports. The main ones are:
*Menu Item* - no coding necessary--just pick from a pull-down menu that shows the application's menus and menu items.
AppleScript - duplicate existing AppleScript-based commands and change them for you needs. (If you really get into AppleScript, you can use the Script Editor to open applications and look at their AppleScript dictionaries.)
*Text Macro* - inserts a block of pre-configured text, such as an email signature, or form letter.
You can also make Commands that run Automator workflows, open Applications by name, open Bookmarks by name, open Files or Folders.
Give your spoken commands names that are 3 to 5 words long. Best practice is probably 3 or 4 words long, a combo of simple/unique/memorable words. For example, "Print This Document" or "Print Window Open" or "Print For Me Baby". If you want to call the spoken command "Beam Up My Print Job" and launch an AppleScript that plays a teleporter sound, be my guest...but at that point you probably don't need much help anymore.
The end result is that you can control Mac applications, with custom spoken commands.
twitter.com/macspeech

Similar Messages

  • AppleScript for address book stopped working in snow leopard

    I had an AppleScript stop working after upgrade to snow leopard. I select an address and it moves it to a group "envelopes" then prints the address in my current document. Later, I make a mail merge document of "envelopes and print out the envelopes for the day. Now it hangs up at the line:
    Add the selection to the group "envelopes"
    What is the new syntax to accomplish this? Not ready to abandon snail mail

    tell application "MacSpeech Dictate Medical"
      set bundleID to (bundle identifier of current context)
    end tell
    set _currentAppName to short name of (info for (path to application id bundleID as alias))
    --adds the selection to the group "envelope" to drag and drop later into a Pages mail merge to print out the day's envelopes
    tell application "Address Book"
      add the selection to the group "envelope"
      save addressbook
    --compile theaddress and print in current document of macspeech dictate medical
      set theContacts to the selection
      repeat with thisPerson in theContacts
      set theName to name of thisPerson
      set theStreetstring to street of first address of thisPerson
      set theStreet to paragraph 1 of theStreetstring
      try
      set theStreet2 to paragraph 2 of theStreetstring
      set theStreet to theStreet & return & theStreet2
      end try
      try
      set theStreet3 to paragraph 3 of the theStreetstring
      set theStreet to theStreet & return & theStreet3
      end try
      set theCity to city of first address of thisPerson
      set theState to state of first address of thisPerson
      set theZip to zip of first address of thisPerson
      end repeat
    end tell
    set theaddress to theName & return & theStreet & return & theCity & ", " & theState & " " & theZip
    tell application "System Events"
      keystroke theaddress
    end tell

  • Applescript for address book

    Is there a way to click on a contact name, have apple script capture first name, last name, address, then print these in a document? I know I can use mail merge in Pages, but can't in other text editors

    OK, sorry. So I dictate medical reports in Macspeech Dictate. I do a bunch at a time. I have to dictate a report to Dr. Jones, so I want to insert using address book:
    Joe Jones, M.D.
    1234 1st St.
    Kansas City, KS 66111
    then I dictate the letter to Dr. Jones, then I dictate the next letter to Dr. Smith, etc.
    at the end of the day's dictation I have a single document that has ~20 medical reports. I have a macro that I've used for 8 yrs in MS Word to split the letters up, save them in individual files, print them properly formatted on letterhead. I recently have switched to Pages & have developed an applescript to do the same thing. I could dictate, save, print letters one at a time, then I could use the script the way you originally wrote it, but my workflow is more efficient to do it all at once. I guess I'm stuck in my ways, but, again, I think it works better to finish the dictation for the whole day and let my macro save, format, and print all the reports at once. So that's why I want to put the addresses in an already made document.
    So here's the code I'm using:
    (I added in 2 lines of code to save the selected addresses in a group "envelope" so I can drag & drop them into a Pages mail-merge document to print out the envelopes for the day's dictation)
    tell application "Address Book"
    --the next 2 lines are to store selected addresses in group envelope that I can drag and drop into a pages merge document to print out all the envelopes for the day's dictation
    add the selection to the group "envelope"
    save addressbook
    set theContacts to the selection
    repeat with thisPerson in theContacts
    set theName to name of thisPerson
    set theStreet to street of first address of thisPerson
    set theCity to city of first address of thisPerson
    set theState to state of first address of thisPerson
    set theZip to zip of first address of thisPerson
    end repeat
    end tell
    set CSZ to theCity & ", " & theState & " " & theZip
    activate application "Macspeech Dictate Medical"
    tell application "System Events"
    keystroke theName
    key code 36
    keystroke theStreet
    key code 36
    keystroke CSZ
    end tell
    I ran this code on my macbook pro running 10.5.8 and my imac running 10.5.8. I made a brand new entry in the address book using a multiline street address and it doesn't put the line breaks. Otherwise, this macro works great. Weird, huh!
    Thanks for your help & patience.

  • A script to run MacSpeech Dictate without touching your computer!

    Hello everyone! I am new to this forum, this is my first AppleScript I have written, it's a real easy one, but I am proud of it! It may be totally useless, but I am still going to post it!
    The script is designed to be put in the main folder of the directory "Username>Library>Speech" and used with the built in "Speech" function of all new macs, to initiate the program "MacSpeech Dictate" application, then shut off the built in "Speech" and open a new dictation note pad.
    I use this when it is late at night and I have an idea for my novel's, or just a weird dream I want to remember. I leave my mac running by my bed and when I wake up with my idea I say, "Begin Dictate" then wait about 5 seconds, then start to talk and the computer records everything I say, then I go back to sleep. I never have to move from my very comfy, very WARM bed!
    Anyway, I hope this might help someone, somewhere.
    tell application "MacSpeech Dictate.app"
    activate
    end tell
    tell application "System Events"
    if UI elements enabled then
    tell process "MacSpeech Dictate"
    set frontmost to true
    tell menu bar 1
    tell menu "File"
    click menu item "New Note Pad"
    end tell
    tell menu "Speech"
    click menu item "Microphone On"
    end tell
    end tell
    end tell
    tell process "Finder"
    key down {command, shift}
    keystroke "z"
    key up {command, shift}
    end tell
    tell process "MacSpeech Dictate"
    set frontmost to true
    end tell
    end if
    end tell
    PS: The dashes aren't part of the script. Just saying, in case someone might not know!

    Try ...
    tell application "MacSpeech Dictate.app" to activate
    tell application "System Events"
    if (UI elements enabled) then
    tell process "MacSpeech Dictate"
    set frontmost to true
    click menu item "New Note Pad" of menu "File" of menu bar 1
    click menu item "Microphone On" of menu "Speech" of menu bar 1
    end tell
    tell process "Finder" to keystroke "z" using command down & shift down
    tell process "MacSpeech Dictate" to set frontmost to true
    end if
    end tell

  • Using MacSpeech Dictate in Leopard

    Has anyone else tried to use Dictate on their computer with more than one user account? It wants you to load the data disk again for the second account (waste of space). It also wants you to register it again but won't accept the activation code as it has already been used. The MacSpeech site has no forum going yet for this product. By the way, it is very much more accurate then iListen.

    There seems to be no "authorization" limitation in effect after you initially complete the registration process (that you're required to do after first installing Dictate). All that seems to occur after completing that online registration is that the Dictate program is instructed to create a special license key file and to store it on your hard drive. Here's the path: (your Home Folder) > Application Support > MacSpeech > Dictate. If you want to install and use Dictate on your other computers with the same Registration Code then simply copy that license file to your other computer, install the program on your other computer, when you get the part that asks if you to register the software, press the "Add License Key" button and navigate to that copied license file. It'll accept it and approve the registration and create a license file in that computer's Home Folder. As far as I can tell you can repeat this process to use Dictate on as many computers as you want -- not that you will, of course, since that would be a violation of their terms of use.
    Message was edited by: ffass2
    Message was edited by: ffass2

  • MacSpeech Dictate Crashes on startup every time since Quicktime 7.6 update

    I had my MacBook Pro 17" working perfectly. I allowed it to install QuickTime update and since then MacSpeech Dictate is failing to start up. This is the error I am getting.
    Imran
    Please copy the information in the crash log that will appear when you click "OK" into an email message, along with the the files named:
    "2009-01-22 22-26-24 Interface.txt" and
    "2009-01-22 22-26-24 Log.txt"
    from the "Troubleshooting" folder that has just been opened in the Finder.
    Version 3671: 22:26:53 MSInterface::ActivateGrammar--DSXGrammar_Activate had error = 7, /build/1.2.1-Release/Dictate/../Recognizer Interface/MSInterface.cpp, line 1618

    The reason for the reply is there isn't any guarantee the problem is with QuickTime 7.6. For example, I've had no problems with it on my machine (but I don't have Dictate installed, so I haven't tested it.) Not all problems arising from a new update are caused by the update. Could be with Dictate or some other dysfunction on your system or other incompatibility. Hence, it's always best to report third-party software problems to the developer first, then find out if the problem is not their software before reporting here. Otherwise we may end up chasing our tails (and tales) only to find the problem isn't with OS X or an update to OS X.

  • IPhone 6 External Mic not working for Siri/Dictation

    I am finding that the external mic on my iPhone 6 works for phone calls and voice memos, but does not work for Siri/Dictation.  When I plug in the earbuds, they work for everything (including Siri/Dictation).
    Was chatting to Apple support who had me reset all settings.  I thought that worked, but realized that after a reset, Siri is off and I was talking to "Voice control" (which works).  When I turned Siri back on, it does not work.
    I have two questions for the community to see if you can help:
    1- I have been assuming this must be a software problem since the mic does work for non-Siri access.  But is that true?  Is there a hardware component that Siri depends on which could be faulty here?
    2- If it is software, what action should I try to address it?  I have done a reset all settings already and that did not help.
    Doug

    Hi, everyone.  I talked to Apple Genius at Apple Store last week, she said it should be a software issue and I needed to reset my iphone 6 plus as a new device and I can not use the backup restore from my iCloud, it was because the microphone bug or glitch can be in the backup also. Ok, followed her advice, erased all contents and set my iphone as a new device , the microphone worked for an hour, but went bad again.  I used "voice memo" app from Apple to test the microphone. It is the best tool since it doesn't involve any provider's network and it doesn't need another person's phone to listen and test.  If you can hear your voice recording clearly, then the mic works.  I tested it 3-4 times a day for a few days now, half of the time the mic doesn't work.  So, set as a new device isn't working. The issue is intermittent and it comes and goes as it likes, so very annoying. I carry my Apple EarPods with me in these past few days ust in case I need to make important phone calls.  Will need to go back to Apple Genius this weekend for sure.  Will give update after the weekend.

  • Looking for a Dictation App for my Iphone and MacBook Pro. Want to send all dictation to Word. I have Dragon.  Should I purchase Dragon Premium or Dragon for Mac?

    Looking for a Dictation App for my Iphone and MacBook Pro.
    Want to send all dictation to Word.
    I have Dragon.  Should I purchase Dragon Premium or Dragon for Mac?

    Care to share which OS you are using?
    OS has its own dictation program. 
    Should I purchase Dragon Premium or Dragon for Mac?
    Only you can make that determination.  Read the system requirements for both and read the reviews.

  • Help with a simple applescript for combining Artist text with Track name

    Hi all,
    I'd like to put together a simple script that takes the artist names from a list of tracks in iTunes and copies the text to the start of the Title name, followed by " - ".
    This is because, e.g. on a classical album, I want the artist names to all be "Classic Collection Gold" but I'd like to keep the artist name contained with the track name. This means when I browse by artist I don't get millions of artists...
    I found this script, which does something kinda similar, but I'm new to script writing so not sure how to do it?
    So I'd like to change:
    Name
    Planets: Mars
    Artist
    Gustav Holst
    Ambum:
    Simply Classical Gold (Disc 2)
    To be:
    Gustav Holst - Planets: Mars
    Artist
    Gustav Holst - Planets: Mars OR BETTER Simply Classical Gold (Disc 2)
    Album
    Simply Classical Gold (Disc 2)
    This script has some ideas in, but I'm not sure how to tweak it....
    "Artist - Name Corrector" for iTunes
    written by Doug Adams
    [email protected]
    v1.6 May 17, 2004
    -- removed ref to selection
    v1.5 April 11 2004
    checks if separator string is in name
    v1.0 April 2 2004
    Get more free AppleScripts and info on writing your own
    at Doug's AppleScripts for iTunes
    http://www.malcolmadams.com/itunes/
    property separator : " - "
    tell application "iTunes"
    if selection is not {} then
    set sel to selection
    repeat with aTrack in sel
    tell aTrack
    if (get name) contains separator then
    set {artist, name} to my texttolist(get name, separator)
    end if
    end tell
    end repeat
    end if
    end tell
    -- == == == == == == == == == == == == == == == ==
    on texttolist(txt, delim)
    set saveD to AppleScript's text item delimiters
    try
    set AppleScript's text item delimiters to {delim}
    set theList to every text item of txt
    on error errStr number errNum
    set AppleScript's text item delimiters to saveD
    error errStr number errNum
    end try
    set AppleScript's text item delimiters to saveD
    return (theList)
    end texttolist
    Message was edited by: Chipstix

    I'm not sure what that script thinks it's doing, but it's essentially doing nothing, so scrub that and start afresh.
    The first thing you need is a way to identify the tracks to change - you don't want to do all tracks in the library (they might have already been munged). A good option is to work on the selected tracks:
    tell application "iTunes"
    if selection is not {} then
    set sel to selection
    You then need to iterate through those items, changing them one-by-one:
    repeat with aTrack in sel
    Now comes the easy part - build a list of the elements you want (in this case you want the name, artist, and album of each track:
    set trackName to name of aTrack
    set trackArtist to artist of aTrack
    set trackAlbum to album of aTrack
    Now you have the information you need, so reset the fields as appropriate:
    set name of aTrack to trackArtist & " - " & trackName
    set artist of aTrack to trackAlbum -- or to trackArtist & " - " & trackName, depending on your choice
    Now clean up by closing off the repeat and tell blocks:
    end repeat
    end tell
    Putting it all together you get:
    tell application "iTunes"
      if selection is not {} then
      set sel to selection
      repeat with aTrack in sel
        set trackName to name of aTrack
        set trackArtist to artist of aTrack
        set trackAlbum to album of aTrack
        set name of aTrack to trackArtist & " - " & trackName
        set artist of aTrack to trackAlbum -- or to trackArtist & " - " & trackName, depending on your choice
      end repeat
    end tell

  • Help Needed: Automator Applescript for Folder Action - Encode Video

    Hi !
    I have created an Automator Applescript for a Folder Action to do the following:
    When a new video file is moved to the target folder (i.e. Download of Vuze is done), automatically launch the Applescript Action that does the followin g(Applescripted):
    1) Using "run shell script" and FFMPEG on a UNIX command line, determine Width/Height, Framerate, Bitrate
    2) Calculate encoding parameters (slightly reduced bitrate, reduced Aspect etc.)
    3) Using "run shell script" with ffmpeg on the command line and the calculated parameters to encode the video file
    At the same time, the action is written to a log file so I know if a file is recognized, when encoding started etc.
    It works fine if I save this Action as an .app, make an alias on the Desktop and drop video files on it.
    It also works fine if I attach the script to a folder as a folder action and drag a video file in there.
    However, when I attach the script as a folder action to the Vuze download folder, it encodes only some video files, i.e. if there was a download of 5 files, chances are good that it will not encode 1 or 2 files out of those 5.
    If for example a second download finishes while the encoding for the first download is still going on, sometimes the second file starts encoding after the first encode finishes, sometimes it does not, the file does not make the log file at all, i.e. the folder action missed it or the automator action dropped it because it was still encoding. Still, sometimes it happens, sometimes not.
    As I need a solution that is 100% accurate, I would like to ask if there are any ideas on how to do this better maybe? As I am not an Applescript Guru, I would need some help to know what works and what doesn't and what the syntax is.
    My main idea right now:
    Similar to how ffmpegX works with its "process" application, have a second script (as .app) that receives the files to be encoded from the automator action and puts them in a queue, then proceeds to encode this queue while the main automator action is free to receive the next file.
    Writing this second app is quite straightforward (a modified version of my current script) but I have some questions I need help with:
    1) How do I call another applescript from within an existing applescript that launches the new applescript in a new process?
    2) How do I pass parameters to this new applescript?
    3) In case of this "Queueing" Idea, once I called the external applescript the first time, how do I make sure when I call next time, that I don't open a second instance of this script but rather pass another queue item to the original instance to be processed?
    Or in general: Is there a better way to achieve this automatic encoding solution that I have not thought about?
    Alternatively:
    Does anyone know how to call the "process" application that comes with the ffmpegX package with the correct parameters to use as a queueing / processing tool?
    Thanks!
    Joe
    Message was edited by: Joe15000
    Message was edited by: Joe15000

    To do this, I created an Automator workflow with an Applescript snippet to change the 'media kind'.
    Here is the 'Run Applescript' workflow step code:
    on run {input, parameters}
              tell application "iTunes"
                        set video kind of (item 1 of input) to movie
              end tell
              return input
    end run
    Prior to this running, I have an 'Import Files into iTunes' workflow step.
    You can switch out 'movie' with: 'TV show', 'music video', or anything in ITLibMediaItemMediaKind.
    Good luck,
    Glenn

  • Error downloading the english language for enhanced dictation.

    I'm trying to setup for enhanced dictation and I keep getting the following error message:
    "an unexpected error happened while downloading the dictation language "english" (United States) try again."
    Can anyone please tell me what's the problem?

    Yes, it is an almost 1 GB file download and takes a while.
    And, since it is a file from Apple and not available as a "stand-alone third party" download, I doubt very seriously that it could be shared from a Google drive; most likely that would not be legal as any software downloads from Apple can only be obtained legally directly from Apple.
    I read that turning off Spotlight helps (I did not do that).
    I just found this older discussion searching here for you:
    can't download the Enhanced Dictation Engine
    Have you tried all of those steps?
    (Note: I did not have to restart the computer for it to work on mine)

  • Automator/Applescript for Pages

    Does anyone know of a good reference for Automator Actions or Applescripts for Pages? I've looked at all the usual websites and no one has any. All I'm trying to do is use a script to automate the process of opening Word docs and save them as Pages files.

    I do not think there is anything really well written and exhaustive on the matter. I have three main sources:
    1. Pages script dictionary (available in ScriptEditor through Open Dictionary > Pages).
    2. This page with a script that goes the opposite way: http://pagesfaq.blogspot.com/2006/11/i-have-one-thousand-pages-documents-to.html
    3. Searching Google for the string "tell application Pages".

  • Repeatable Safari Crash on FaceBook text box If MacSpeech Dictate running

    If MacSpeech Dictate is running (which works quite well, and dictates into almost any window except Adobe AIR based apps like TweetDeck in my experience), even if Dictate recognition is OFF, if text is pasted into a FaceBook text/status page it is 100% going to crash Safari. If typing text in the same situation the crash likelihood is 80%.
    Just sharing here in case someone saw the same situation.
    Imran

    MacSpeech worked around and resolved this bug in an update.

  • Difference between Applescript for Intel & PPC?

    Well little did I know I'd want to write an Applescript for PowerPC again, but after updating to Lion, I forgot to keep a copy of Applescript Editor hanging around on my 10.4.11 partition.     I noticed the Applescripts I wrote for 10.6.8 and earlier wouldn't work in Lion, and I had to recompile them with the Script Editor in Lion. Now I have a new Applescript I wish to write for Snow Leopard and earlier, but can't since I don't have my old Snow Leopard or earlier Script Editor.
    1. Is there a place I can download the Applescript Editor itself for 10.4.11
    2. Do I have to extract the program from my 10.4 installer discs for my iMac 5,1 with Pacifist?
    3. Could I do something with Textwrangler to edit my script so it is an application that runs on Rosetta and PowerPC?
    Thank you.

    The compiled scripts should not differ, just the single-file application format - script applications are now saved as applicaion bundles like everything else.

  • Applescript for Mail Question

    Is it possible to create an Applescript for Mail, that, when an email with a specific subject line arrives in my inbox, an attached photograph would get sent immediately in response to the person who sent the email.  The subject lines would vary (e.g., people_1, or, places_16).  Every subject line would have a corresponding photo located somewhere on my hard drive (there would be hundreds of possibilities - the catalogue would be concentrated in one place).  So, for example, when "places_21" hits my Mail in box, an email would be generated in response, automatically, with a photo (places_21) attached.  Thank you!  Marcos

    Actually, it's not that hard to do, it's just that there are a lot of use cases, and a lot of caveats to consider.
    For example, do you intend/expect to work from a predefined list of image file names? Or do you want/expect to react to any filename that's requested?
    You say that the files would be 'somewhere on my hard drive'... how does the script know where to look? How does it resolve filename conflicts? What should happen if a file can't be found?
    As fane suggests, you should also consider an audit log, so you can see who asked for what, and when, along with errors that occurred on the way.
    So it's entirely do-able, just a lot of questions to answer before you get started.

Maybe you are looking for

  • How to convert date format automatically

    My question is that how to define fix format of date for hole form, suppose i enter the data in date column the date should take automatically format how to this for example, type only 01012010 when i press enter after that at once show 01-01-2010. b

  • 6502 = ORA-06502: PL/SQL: numeric or value error: character string buffer

    i'm getting this error when i try to do the following 6502 = ORA-06502: PL/SQL: numeric or value error: character string buffer too small declare str1Query varchar2(32767); str2Query varchar2(32767); str3Query varchar2(32767); str31Query varchar2(327

  • Periodic data for 0balance in 0FI_GL_12

    hi guys, how can we get periodic data for 0balance key figure for datasource 0FI_GL_12 ?

  • Create filter in Process Flow

    hello, I wanna figure out how to make filters in Process Flow, because I don't see them. Something like: - if to_char(sysdate,'yyyy') from dual > 2006 then include a mapping. thank you br

  • Multiple Business systems

    Hello, Can Multiple Business systems be associated with one Technical system in SLD and assigned in D ? Regards,