protected override void OnNavigatedTo(NavigationEventArgs e) { base.OnNavigatedTo(e); // Get data objects and place them into an ObservableCollection List <CustomDataObject> tempList = CustomDataObject.GetDataObjects(); ObservableCollection <CustomDataObject> Items = new ObservableCollection <CustomDataObject>(tempList); ObservableCollection <CustomDataObject> Items2 = new ObservableCollection <CustomDataObject>(tempList); BasicGridView.ItemsSource = Items2; ContentGridView.ItemsSource = Items; StyledGrid.ItemsSource = Items; ActualColSpace = 5; ActualRowSpace = 5; ActualMaxItems = 3; MaxItems.Text = ActualMaxItems.ToString(); DisplayDT.Value = @"<!-- ImageTemplate: --> <DataTemplate x:Key='ImageTemplate' x:DataType='local1: CustomDataObject'> <Image Stretch = 'UniformToFill' Source = '{x:Bind ImageLocation}' AutomationProperties.Name = '{x:Bind Title}' Width = '190' Height = '130' AutomationProperties.AccessibilityView = 'Raw'/> </DataTemplate> "; }
protected override void OnNavigatedTo(NavigationEventArgs e) { base.OnNavigatedTo(e); Control1.ItemsSource = CustomDataObject.GetDataObjects(); }