RadChart
rptChart= new RadChart();
rptChart.DefaultView.ChartArea.PaletteBrushes.Add(
new SolidColorBrush(Colors.Blue));
rptChart.DefaultView.ChartArea.Margin =
new Thickness(0,0,0,5);
rptChart.DefaultView.ChartArea.AxisX.IsDateTime =
true;
rptChart.DefaultView.ChartArea.AxisX.AutoRange =
false;
rptChart.DefaultView.ChartArea.AxisX.DefaultLabelFormat =
"MM/dd/yyyy";
rptChart.DefaultView.ChartArea.AxisX.LabelRotationAngle = 25;
rptChart.DefaultView.ChartArea.AxisX.Step = 1;
rptChart.DefaultView.ChartArea.AxisX.LabelStep = 5;
rptChart.DefaultView.ChartArea.AxisX.MaxValue = MaxDateShown;
rptChart.DefaultView.ChartArea.AxisX.MinValue = MinDateShown;
rptChart.DefaultView.ChartLegend.Visibility =
Visibility.Collapsed;
rptChart.ItemsSource = Data; //Data is an observableCollection
rptChart.MaxHeight = 200;
rptChart.MaxWidth = 450;
rptChart.MinWidth = 350;
rptChart.MinHeight = 150;
Telerik.Windows.Controls.Charting.
SeriesMapping sm = new Telerik.Windows.Controls.Charting.SeriesMapping();
sm.LegendLabel =
"legendLabel";
sm.SeriesDefinition =
new Telerik.Windows.Controls.Charting.LineSeriesDefinition();
sm.ItemMappings.Add(
new Telerik.Windows.Controls.Charting.ItemMapping("ReportDate", Telerik.Windows.Controls.Charting.DataPointMember.XValue));
sm.ItemMappings.Add(
new Telerik.Windows.Controls.Charting.ItemMapping("Quantity", Telerik.Windows.Controls.Charting.DataPointMember.YValue));
rptChart.SeriesMappings.Add(sm);
I then add the chart to the grid for printing. Any ideas on what is preventing the line from showing up? The chart shows up on the printed page formatted correctly, just no line.
Thanks,
Jay.