public partial class MainPage : PhoneApplicationPage { Appointments appointments = new Appointments(); // Constructor public MainPage() { InitializeComponent(); appointments.SearchCompleted += new EventHandler<appointmentssearcheventargs>(appointments_SearchCompleted); SearchCalendar(); // Sample code to localize the ApplicationBar //BuildLocalizedApplicationBar(); } private void SearchCalendar() { appointments.SearchAsync(DateBox.Value.Value, DateBox.Value.Value.AddDays(1), null); } private void DateBox_ValueChanged(object sender, DateTimeValueChangedEventArgs e) { SearchCalendar(); } void appointments_SearchCompleted(object sender, AppointmentsSearchEventArgs e) { if (e.Results.Count() == 0) { MessageText.Text = "no events for the selected day"; } else { MessageText.Text = e.Results.Count() + " events found"; DateList.ItemsSource = e.Results; } }
TargetInvocationException
InnerException
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)