Saturday, April 30, 2016

Adding Terms to a Secondary Studio Termbase Using Dragon Commands

I have always wanted to be able to add terms to a secondary termbase while I'm working in Studio. As we all know, this is not possible out of the box, but with a Dragon script, it is now as easy as saying "Add term to secondary termbase".

Required software: Dragon NaturallySpeaking Professional 13, or DNS 13 Premium + KnowBrainer 2016, or Dragon Professional Individual 14, Studio and Multiterm

* For a very basic intro to creating commands, you may want to read this first.

I've created two scripts for this: one that pastes the source term into Multiterm, where the user will have to type or dictate the target term next, and another one that automatically populates the dictated target term, sort of like Add New Term and Quick Add New Term features in Studio, except that the terms will be added to whatever termbase is open and active in Multiterm.

Step 1: Create your commands in Dragon or KnowBrainer

Feel free to copy and paste the scripts below.

Script 1: Add selected source term to secondary termbase
Example of what you say: "Add term to secondary termbase"; this is the command name and must be spoken exactly as entered in the script. You can choose your own command name.

Command name: Add term to secondary termbase (adapt to whatever you prefer)
Description: Adds the selected source term to a secondary termbase (opens Multiterm) - not open-ended

Sub Main
SendKeys "^c"
Wait 1
AppBringUp "C:\Program Files (x86)\SDL\SDL MultiTerm\MultiTerm12\MultiTerm.exe"
Wait 1
SendKeys "{F3}{Tab}"
Wait .2
SendKeys "{Tab}^v"
Wait .5
SendKeys "{Tab}"
End Sub

The above script is shown in the KnowBrainer Command Editor window


Script 2: Add selected source term and dictated target term to secondary termbase
Example of what you say: "Add term worker", where "worker" is the target term that will be added to the Multiterm entry

Command name: Add term <dictation> (if you haven't, please read the section about open-ended commands here)
Description: Adds the selected source term to a secondary termbase, inserts the dictated term into the target field, and saves the entry

Sub Main
SendKeys "^c"
Wait 1
AppBringUp "C:\Program Files (x86)\SDL\SDL MultiTerm\MultiTerm12\MultiTerm.exe"
Wait 1
SendKeys "{F3}{Tab}"
Wait .2
SendKeys "{Tab}^v"
Wait .5
SendKeys "{Tab}"
Wait .5
SendKeys ListVar1
Wait .2
SendKeys "{Enter}"
SendKeys "{F12}"
End Sub

The above script is shown in the KnowBrainer Command Editor window

Using your commands
Before running your commands, open your secondary termbase in Multiterm.  If the termbase is added to you current Studio project, you will have access to the terms you add as you translate. You can minimize Multiterm after doing this.


That's all you need to do. If you're using KnowBrainer, you will see the new commands in the Sidebar, ready to be used. KnowBrainer helpfully lists the commands available for the active program in its sidebar, and highlights the recognized commands as they are used.



And to finish, here are the commands in action!








3 comments:

  1. Very important page this and i think students are like it so much. Because they find more information about study in here those helps them to interested in education as well as.

    ReplyDelete