Esempio n. 1
0
        public CustomTemplate()
        {
            Resources.MergedDictionaries.Add(SfChart.Resources.ColorModelResource.Resource);
            this.InitializeComponent();
            viewModelScatter = new ScatterChartViewModel();
            viewModelSpline  = new SplineChartViewModel();
            viewModelBar     = new BarChartViewModel();

            if (AnalyticsInfo.VersionInfo.DeviceFamily != "Windows.Mobile")
            {
                Basic_Chart5.Series[0].ItemsSource = viewModelBar;
            }

            temp1 = MainGrid3.Resources["DataTemplate1"] as DataTemplate;
            temp2 = MainGrid3.Resources["DataTemplate2"] as DataTemplate;
            temp3 = MainGrid3.Resources["DataTemplate3"] as DataTemplate;
            temp4 = MainGrid3.Resources["DataTemplate4"] as DataTemplate;
            temp5 = MainGrid3.Resources["DataTemplate5"] as DataTemplate;
        }
        public CustomTemplate()
        {
            this.InitializeComponent();
            viewModelColumn  = new ColumnChartViewModel();
            viewModelColumn1 = new ColumnChartViewModel1();
            viewModelScatter = new ScatterChartViewModel();
            viewModelSpline  = new SplineChartViewModel();
            viewModelBar     = new BarChartViewModel();

            if (AnalyticsInfo.VersionInfo.DeviceFamily != "Windows.Mobile")
            {
                Basic_Chart5.Series[0].ItemsSource  = viewModelColumn;
                Basic_Chart5.Series[1].ItemsSource  = viewModelColumn;
                Basic_Chart51.Series[0].ItemsSource = viewModelColumn1;
            }

            temp1 = MainGrid3.Resources["DataTemplate1"] as DataTemplate;
            temp2 = MainGrid3.Resources["DataTemplate2"] as DataTemplate;
            temp3 = MainGrid3.Resources["DataTemplate3"] as DataTemplate;
            temp4 = MainGrid3.Resources["DataTemplate4"] as DataTemplate;
            temp5 = MainGrid3.Resources["DataTemplate5"] as DataTemplate;
        }