You are reading help file online using chmlib.com
|
Interface: ISpeechRecoContext Events
The RequestUI event occurs when the speech recognition (SR) engine requests additional information from the user.
Though not required, SR engines may employ a process improvement procedure and request additional information from the user. For example, if the recognition attempts are consistently poor or if the engine detects consistent background interference, the SR engine could request that the application use the training or microphone wizard. This event is a suggestion by the SR engine to run the particular UI. The application may choose to initiate the UI or may ignore the request.
SpeechRecoContext.RequestUI(
StreamNumber As Long,
StreamPosition As Variant,
UIType As String
)
See ISpeechRecognizer.DisplayUI and ISpeechRecognizer.IsUISupported for additional information.
The following Visual Basic code shows a typical RequestUI event. Since the SR engine initiates the call, reproducing the event is difficult. However, if the application receives this event, the code displays the user training wizard. It is the same training wizard that is available through the Speech properties in Control Panel.
Private Sub RC_RequestUI(ByVal StreamNumber As Long, ByVal StreamPosition As Variant, ByVal UIType As String)
If UIType = SpeechUserTraining Then
RC.Recognizer.DisplayUI Form1.hWnd, "My User Training", SpeechUserTraining, vbNullString
End If
End Sub
You are reading help file online using chmlib.com
|