private async void StartSpeechRecognizer() { // Compile the loaded GrammarFiles SpeechRecognitionCompilationResult compilationResult = await _recognizer.CompileConstraintsAsync(); // If successful, display the recognition result. if (compilationResult.Status == SpeechRecognitionResultStatus.Success) { Debug.WriteLine("Result: " + compilationResult.ToString()); SpeechContinuousRecognitionSession session = _recognizer.ContinuousRecognitionSession; try { await session.StartAsync(); } catch (Exception e) { //TODO this needs to report to the user that something failed. //also potentially write to a log somewhere. Debug.WriteLine(e.Data); } } else { //TODO this needs to report to the user that something failed. //also potentially write to a log somewhere. Debug.WriteLine("Status: " + compilationResult.Status); } }