Example #1
0
        private async void DropSessionEnd(object sender, DragEventArgs e)
        {
            try
            {
                if (null != DraggedSession)
                {
                    CalendarEvents calEvents = await CalendarEvents.CreateCalendarInstance();

                    await calEvents.AddOrUpdateCalendarEvent(DraggedSession.ToCalendarEvent());

                    DisplayCalendarEventsForDay(System.Convert.ToDateTime(DraggedSession.Start));
                }
            }
            catch { }
        }
Example #2
0
        private async void addCalButtonClick(object sender, RoutedEventArgs e)
        {
            if (SessionListView.SelectedItems.Count <= 0)
            {
                return;
            }

            Session item = SessionListView.SelectedItem as Session;

            CalendarEvents calEvents = await CalendarEvents.CreateCalendarInstance();

            CalendarEvent calendarEvent = item.ToCalendarEvent();
            await calEvents.AddOrUpdateCalendarEvent(calendarEvent);

            DisplayCalendarEventsForDay(System.Convert.ToDateTime(item.Start));
        }