SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, iOS Chart, Android Chart and JavaScript Chart Components


I use SciChart in a datagrid as a Sparkline.
Using a NumericAxis the first and last column is displayed in half.
By replacing the X axis by CategoryNumericAxis chart doesnt works.

<s:SciChartSurface Height="200" Width="300" RenderPriority="Low" MaxFrameRate="24" Background="Black">
    <s:FastColumnRenderableSeries DataSeries="{Binding Volume}" DataPointWidth="0.75" Fill="Red" Stroke="Black"/>
    <s:CategoryNumericAxis AutoRange="Always" DrawMinorGridLines="False" Visibility="Hidden" DrawMajorGridLines="False" DrawMajorBands="False" />
    <s:NumericAxis AutoRange="Always" DrawMinorGridLines="False" DrawMinorTicks="False" DrawMajorGridLines="False" DrawMajorBands="False" DrawMajorTicks="False" >
        <s:DoubleRange Min="0" />

and code

public XyDataSeries<int, float> Volume { get; set; } = new XyDataSeries<int, float>();

   Volume.Append(0, 500);
   Volume.Append(1, 100);
   Volume.Append(2, 1000);
   Volume.Append(3, 700);
   Volume.Append(4, 600);
   Volume.Append(5, 300);
  • You must to post comments

Recently someone reported the bug that CategoryNumericAxis throws when DataSeries TX is int.

The good news is, we have fixed that and published it to our Nuget feed.

If you update to the latest version (v4.2.0) of SciChart, it will work. Or, if you cannot update, as a workaround you can set TX=double and it will also work.

Best regards,

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.