Logarithmic C1Chart not preserving holes

Posted by: steven.evans on 31 July 2018, 10:35 am EST

    • Post Options:
    • Link

    Posted 31 July 2018, 10:35 am EST

    The attached xml file is a save of a C1Chart.

    CAP Cat A SPO.zip

    It loads fine however when you look at the data for the series the hole values are not appearing as “(hole)”. Changing the axis to auto scale results in the chart showing the hole value as a chart value.

    Is there a work round to fix this? If needs be i can pre-process the file.

  • Posted 1 August 2018, 5:40 am EST

    Hi Steven,

    The xml file you’ve shared does not contains any information regarding data holes. Hence when it loads the hole values seems to be missing. To resolve this you can set any specific value as hole using the ChartData.Hole property as shown below:

    chart.ChartGroups[0].ChartData.Hole = -1000
    

    You can also use double.NaN for the same purpose. C1Chart treats double.NaN in data as a hole. Please refer the attachment for sample and xml file as an example.

    Hope it helps.

    Regards,

    Basant

    HolesInC1Chart.zip

  • Posted 1 August 2018, 6:05 am EST

    Thanks for the reply. Just a for interest why is the default Hole value (3.40282346638529E+38) which is used in the file not being recognised.

  • Posted 2 August 2018, 7:30 am EST

    Any chances that you are loading and saving the file on different systems? At my end, float.MaxValue is shown as 3.4028234663852886E+38 and hence while loading your xml the holes are not shown. Whereas, if I save a new xml the holes are saved as 3.4028234663852886E+38 only and on loading the same the holes are shown correctly. So probably it is the difference of float.MaxValue on different systems that the holes are not getting recognized.

    Thank you.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels