private void Button_Click_1(object sender, RoutedEventArgs e) { try { ReviewData data = new ReviewData(iEventName.Text, iName.Text, (iDay.SelectedItem as ComboBoxItem).Content.ToString(), (iMonth.SelectedItem as ComboBoxItem).Content.ToString(), (iYear.SelectedItem as ComboBoxItem).Content.ToString(), (iHH.SelectedItem as ComboBoxItem).Content.ToString(), (iMM.SelectedItem as ComboBoxItem).Content.ToString(), iIniteeName.Text, iImageBox.Source); this.Frame.Navigate(typeof(Screen03), data); } catch (Exception) { } }
/// <summary> /// Populates the page with content passed during navigation. Any saved state is also /// provided when recreating a page from a prior session. /// </summary> /// <param name="navigationParameter">The parameter value passed to /// <see cref="Frame.Navigate(Type, Object)"/> when this page was initially requested. /// </param> /// <param name="pageState">A dictionary of state preserved by this page during an earlier /// session. This will be null the first time a page is visited.</param> protected override void LoadState(Object navigationParameter, Dictionary <String, Object> pageState) { try { ReviewData obj = navigationParameter as ReviewData; iDetail.Text = "Hi " + obj.Initive + ", I'd like to celebrate my " + obj.Event + " with you on " + obj.Day + "/" + obj.Month + "/" + obj.Year + ". The party shall begin on " + obj.Hour + ":" + obj.Minute + " . A Warm Welcome at my (" + obj.Name + "'s) " + obj.Event + "."; this.title = obj.Name + " " + obj.Event; iImage.Source = obj.Image; Description = "I'd like to celeberate my " + obj.Event + " with u."; src = (iImage.Source as BitmapImage).UriSource.AbsoluteUri.Replace("ms-appx:/", "ms-appx:///"); } catch (Exception) { } // var item = (SampleDataItem)navigationParameter; // this.DefaultViewModel["Group"] = item.Group; // this.DefaultViewModel["Items"] = item.Group.Items; // spMain.DataContext = item; DataTransferManager.GetForCurrentView().DataRequested += Screen03_DataRequested; }
private void Button_Click_1(object sender, RoutedEventArgs e) { try { ReviewData data = new ReviewData( iEventName.Text, iName.Text, (iDay.SelectedItem as ComboBoxItem).Content.ToString(), (iMonth.SelectedItem as ComboBoxItem).Content.ToString(), (iYear.SelectedItem as ComboBoxItem).Content.ToString(), (iHH.SelectedItem as ComboBoxItem).Content.ToString(), (iMM.SelectedItem as ComboBoxItem).Content.ToString(), iIniteeName.Text, iImageBox.Source); this.Frame.Navigate(typeof(Screen03), data); } catch (Exception) { } }