When I try to set a language to SpeechRecognize (Windows Phone 8.1) it runs an exception. But in documentation tells me to do the way I'm doing D;
This works:
private async void Button_Click_1(object sender, RoutedEventArgs e)
{
var rec = new SpeechRecognizer();
await rec.CompileConstraintsAsync();
rec.UIOptions.AudiblePrompt = "Aguardando o comando";
var stream = await rec.RecognizeWithUIAsync();
}
This doesn't work:
private async void Button_Click_1(object sender, RoutedEventArgs e)
{
var rec = new SpeechRecognizer(new Windows.Globalization.Language("pt-BR"));
await rec.CompileConstraintsAsync();
rec.UIOptions.AudiblePrompt = "Aguardando o comando";
var stream = await rec.RecognizeWithUIAsync();
}
Someone PLEASE could help me ?
I think that is because your Locale you have installed is not that language. If you want to know for sure, try this: