在WPF Charting工具包中移动网格线

时间:2014-08-07 23:06:47

标签: c# wpf charts

是否有可能在WPF Charting工具包中移动网格线。我有以下XAML代码:

<chartingToolkit:Chart Name="lineChart" 
                       Title="Statistik" 
                       FontSize="16"
                       PlotAreaStyle="{StaticResource PlotAreaStyle}"
                       FontFamily="Comic Sans MS" 
                       VerticalAlignment="Stretch"
                       Margin="73,10,10,80"
                       Background="White"
                       HorizontalAlignment="Stretch">
   <chartingToolkit:LineSeries Title="Solgt"
                               Name="seriesSolgt"
                               DependentValuePath="Value" 
                               IndependentValuePath="Key"
                               IsSelectionEnabled="True">
      <chartingToolkit:LineSeries.DependentRangeAxis>
         <chartingToolkit:LinearAxis Orientation="Y"                        
                                     Title="Beløb"
                                     ShowGridLines="True" />
      </chartingToolkit:LineSeries.DependentRangeAxis>
   </chartingToolkit:LineSeries>
   <chartingToolkit:LineSeries Title="Betalt"
                               Name="seriesBetalt"
                               DependentValuePath="Value" 
                               IndependentValuePath="Key" 
                               IsSelectionEnabled="True" />
   <chartingToolkit:LineSeries Title="Skylder"
                               Name="seriesSkylder"
                               DependentValuePath="Value" 
                               IndependentValuePath="Key"
                               IsSelectionEnabled="True" />
   <chartingToolkit:Chart.Axes>
      <chartingToolkit:CategoryAxis Orientation="X" 
                                    Title="Dato"
                                    ShowGridLines="True"
                                    GridLineStyle="{StaticResource GridLineStyle}" />
   </chartingToolkit:Chart.Axes>
</chartingToolkit:Chart>

我的图表看起来像这样:

enter image description here

我想将垂直网格线移到点上。

0 个答案:

没有答案