KnowBrainer Speech Recognition
Decrease font size
Increase font size
Topic Title: Complex lists not working
Topic Summary:
Created On: 12/13/2020 08:10 PM
Status: Post and Reply
Linear : Threading : Single : Branch
 Complex lists not working   - Todachen - 12/13/2020 08:10 PM  
 Complex lists not working   - speechpro - 12/13/2020 10:45 PM  
 Complex lists not working   - Alan Cantor - 12/13/2020 11:06 PM  
 Complex lists not working   - Todachen - 12/13/2020 11:22 PM  
Keyword
 12/13/2020 08:10 PM
User is offline View Users Profile Print this message

Author Icon
Todachen
Junior Member

Posts: 37
Joined: 09/30/2020

 

I have a complex list through which I am attempting to use written-form\spoken-form as the list items in order to populate the Y axis of a SetMousePosition step. I have read chapter 5 of Larry's Allen's book where he describes complex lists relying on Dragon's ability to distinguish written-form\spoken-form list items. I also see that this is described on page 12 in Dragon' down s own manual on scripting.
Here are some examples of some of the items in the list:
159\profile
173\class summary
188\attendance
203\schedule
231\IHP
231\health plan
231\individual health plan
Here's the command:
Sub Main
SendKeys "^0"
Wait .01
SetMousePosition 1, 58, ListVar1
Wait 0.1
ButtonClick 1,1
End Sub
When I execute the macros, it opens in error message indicating that the entire line of text for the item is being recognized, i.e., "203\schedule", and that it is not a valid input for the Y access. So Dragon is not distinguishing the spoke-form\written-form distinction that Allen describes in his book. For example, instead of inputting "203" as the Y coordinates, it inputs "203\schedule". In this example, I'm intending for the word "schedule" to act as a voice trigger, populating the y-axis with "203". 
In order to verify that it's not a problem with the way I have coded anything above, I tried the following macro
Sub Main
SendKeys ListVar1
End Sub
This was of no avail. So does anybody know why Dragon is not distinguishing spoken-form\written-form?


-------------------------

My voice computer: W10/DPI 15.6/KB2017/VC 2020 on a Intel Core i7-8559U CPU @ 2.70GHz, 16gb DDR4, Sennheiser ME 3D 431 II / Roccat Juke – ROC-14-11-AM



 12/13/2020 10:45 PM
User is offline View Users Profile Print this message


speechpro
Senior Member

Posts: 86
Joined: 11/09/2006

Assuming all your list entries are three digits before the \... - you need to convert the 3 character string to a numeric value
Sub Main
yval = val(left(ListVar1,3))
SendKeys "^0"
Wait .01
SetMousePosition 1, 58, yval
Wait 0.1
ButtonClick 1,1
End Sub
 12/13/2020 11:06 PM
User is offline View Users Profile Print this message


Alan Cantor
Top-Tier Member

Posts: 4348
Joined: 12/08/2007

Larry seemed to prefer using the "Mid" and "Instr" functions when extracting values from a list:

Let yval = Mid(ListVar1, 1, Instr(ListVar1, "\") -1)

But if the list entries to the left of the \ always consist of three characters, this simpler instruction might work:

Let yval = Left(ListVar1, 3)

By the way, "Wait .01" probably won't make a difference. If you find you must wait at that point, try Wait .1 or .3 or .5
 12/13/2020 11:22 PM
User is offline View Users Profile Print this message

Author Icon
Todachen
Junior Member

Posts: 37
Joined: 09/30/2020

Yes! I see now. Thank you. I've got to extract the written-form string in the code itself. I thought for a 2nd there that Dragon did that natively.

-------------------------

My voice computer: W10/DPI 15.6/KB2017/VC 2020 on a Intel Core i7-8559U CPU @ 2.70GHz, 16gb DDR4, Sennheiser ME 3D 431 II / Roccat Juke – ROC-14-11-AM

Statistics
32325 users are registered to the KnowBrainer Speech Recognition forum.
There are currently 1 users logged in.
The most users ever online was 12124 on 09/09/2020 at 04:59 AM.
There are currently 620 guests browsing this forum, which makes a total of 621 users using this forum.

FuseTalk Standard Edition v4.0 - © 1999-2022 FuseTalk™ Inc. All rights reserved.