Click here to Skip to main content
15,895,538 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
XML
<controls:ChildWindow x:Class="ProView.Views.LinkConditioning"
           xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
           xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk"
           xmlns:toolkit="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Toolkit"
           xmlns:sys="clr-namespace:System;assembly=mscorlib"
           xmlns:telerikCharting="clr-namespace:Telerik.Windows.Controls.Charting;assembly=Telerik.Windows.Controls.Charting"
 xmlns:charting="clr-namespace:System.Windows.Controls.DataVisualization.Charting;assembly=System.Windows.Controls.DataVisualization.Toolkit"
           xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
           xmlns:commands="clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Extras.SL4"
           xmlns:models="clr-namespace:Data.ViewModels"

           Width="900" Height="500"
           Title="LinkConditioning" Loaded="ChildWindow_Loaded" Closed="ChildWindow_Closed" >

  <StackPanel Orientation="Horizontal" VerticalAlignment="Top"  Margin="0,8,0,0">
        <telerik:RadCartesianChart Palette="Windows8">
                    <telerik:LineSeries CategoryBinding="Date" ValueBinding="value" ItemsSource="{Binding Data}" />
                    <telerik:RadCartesianChart.HorizontalAxis>
                        <telerik:DateTimeContinuousAxis MajorStepUnit="Second"
                                                LabelInterval="5"
                                                LabelFormat="HH:mm:ss.f" FontFamily="Segoe UI"
                                                Visibility="Collapsed"
                                                 />
                    </telerik:RadCartesianChart.HorizontalAxis>
                    <telerik:RadCartesianChart.VerticalAxis>
                        <telerik:LinearAxis Minimum="500"
                                    MajorStep="500"
                                    Maximum="2000" FontFamily="Segoe UI" />
                    </telerik:RadCartesianChart.VerticalAxis>
                    <telerik:RadCartesianChart.Grid>
                        <telerik:CartesianChartGrid MajorLinesVisibility="Y" MajorYLineDashArray="3,4" />
                    </telerik:RadCartesianChart.Grid>
                </telerik:RadCartesianChart>
            </StackPanel>

</controls:ChildWindow>


CSS
using System;
using System.Windows.Browser;
using Telerik.Windows.Controls;
using Telerik.Windows.Data;
using System.IO;


namespace Data.Views
{
    public partial class DataCollections : ChildWindow
    {

        DataCollections objDataCollections ;



        public DataCollections (DataCollections  model)
        {
            InitializeComponent();
            this.DataContext = model;
            objDataCollections = model;
        }
    }
}


When i run or bulid the project i got below message. Pls Help me..

i got this error in
C#
this.DataContext = model;
this line

The invocation of the constructor on type
'Telerik.Windows.Controls.RadCartesianChart' that matches the specified binding constraints threw an exception. [Line: 48 Position: 52]

The type initializer for 'Telerik.Windows.Controls.RadCartesianChart' threw an exception.
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900