private void sayOrder_TurnStarting(object sender, TurnStartingEventArgs e) { this.sayOrder.MainPrompt.SetText("You Ordered a "); this.sayOrder.MainPrompt.AppendText(this.askColor.RecognitionResult.Text); this.sayOrder.MainPrompt.AppendText(" "); this.sayOrder.MainPrompt.AppendText(this.askSize.RecognitionResult.Text); this.sayOrder.MainPrompt.AppendText(" "); this.sayOrder.MainPrompt.AppendText(this.askProduct.RecognitionResult.Text); }
private void sayAppointment_TurnStarting(object sender, TurnStartingEventArgs e) { //Read First Calendar Event, We could use the navigablelist here to read all //but for now we will just read the first one CalendarObject calendarEvent = _calendarList[0]; this.sayAppointment.MainPrompt.ClearContent(); this.sayAppointment.MainPrompt.AppendText("The selected appointment, {0}, starts on ", calendarEvent.Subject); this.sayAppointment.MainPrompt.AppendTextWithHint(calendarEvent.StartDate.ToLongDateString(), Microsoft.SpeechServer.Synthesis.SayAs.Date); this.sayAppointment.MainPrompt.AppendText(" at "); this.sayAppointment.MainPrompt.AppendBreak(Microsoft.SpeechServer.Synthesis.PromptBreak.Small); this.sayAppointment.MainPrompt.AppendTextWithHint(calendarEvent.StartDate.ToShortTimeString(), Microsoft.SpeechServer.Synthesis.SayAs.Time); this.sayAppointment.MainPrompt.AppendText(" and ending at "); this.sayAppointment.MainPrompt.AppendTextWithHint(calendarEvent.EndDate.ToShortTimeString(), Microsoft.SpeechServer.Synthesis.SayAs.Time); this.sayAppointment.MainPrompt.AppendBreak(Microsoft.SpeechServer.Synthesis.PromptBreak.Small); this.sayAppointment.MainPrompt.AppendText(" and it is located in "); this.sayAppointment.MainPrompt.AppendText(calendarEvent.Location); this.sayAppointment.MainPrompt.AppendBreak(Microsoft.SpeechServer.Synthesis.PromptBreak.Small); }