Vocola.net
Vocola 3.1 Function Library
ReplaceInActiveText(oldText, newText)
Namespaces LibraryDictation ► ReplaceInActiveText
Modifies specified text in recently-dictated phrases.
Syntax
ReplaceInActiveText(oldText, newText)
Parameters
oldText
Text that should be replaced.
newText
Replacement text.
Remarks
This function replaces the most recent occurrence of oldText with newText in active dictation. Active dictation contains all phrases dictated since the last command, possibly separated by pauses.
Examples
CopyCapitalize a word in a recently-spoken phrase
Cap <_vocolaDictation> = Dictation.ReplaceInActiveText($1, String.Capitalize($1));
If you said "The town public library (pause) is excellent", and then "Cap public library", you would see "The town Public Library is excellent".

The special variable <_vocolaDictation> matches any series of words in active dictation. Those words are then capitalized using Capitalize, and both the original and capitalized versions are passed to ReplaceInActiveText.

Assembly: VocolaFunctionLibrary (Module: VocolaFunctionLibrary) Version: 3.1.1.0 (3.1.1.0)