private async void lbSessions_SelectionChanged(object sender, SelectionChangedEventArgs e) { if (lbSessions.SelectedItem != null) { try { currentSession = null; currentScreens = null; txbCurrentSession.Text = ""; lbScreens.ItemsSource = null; currentSession = lbSessions.SelectedItem as ExamSession; var res = await RestClient.GetScreenshotFromSession(currentSession.id); currentScreens = JsonConvert.DeserializeObject <ScreenshotSessionData>(res); lbScreens.ItemsSource = currentScreens.Shots; txbCurrentSession.Text = currentSession.student + " [Status:" + currentSession.status + "]"; } catch (Exception ex) { await this.ShowMessageAsync("Error bij lbSessions_SelectionChanged ", "Error=" + ex.Message); } } }
//public FullImgWindow() //{ // InitializeComponent(); //} public FullImgWindow(ScreenshotSessionData allscreenin, ExamSession currentSessionin) { InitializeComponent(); allScreens = allscreenin; currentSession = currentSessionin; }