Is it possible to have "custom" labeling in the way that I control which label is displayed?
For example if I have a series of 20 datapoints, how can I set a label to just show the X-axis label on datapoint, say, 12 and 14 only? I tried setting the other datapoint labels to Nothing and empty string but it still displays a value.
Thanks in advance.
You can hide X-axis labels with:
<igChart:XamChart>
<igChart:XamChart.Axes>
<igChart:Axis AxisType="PrimaryX">
<igChart:Axis.Label>
<igChart:Label Visible="False" />
</igChart:Axis.Label>
</igChart:Axis>
</igChart:XamChart.Axes>
This turns labeling off for the entire X axis. How do I specify showing the label for a specific datapoint ?
For example, my series has 20 datapoints, and I want to show the X axis label for datapoint 5 only.
Thanks!
You can try:
<igChart:Label Format="{}{0: }" />
<igChart:XamChart.Series>
<igChart:Series>
<igChart:Series.DataPoints>
<igChart:DataPoint Value="1" />
<igChart:DataPoint Value="2" />
<igChart:DataPoint Value="3" />
<igChart:DataPoint Value="4" />
<igChart:DataPoint Value="5" Label="The Label" />
<igChart:DataPoint Value="6" />
<igChart:DataPoint Value="7" />
<igChart:DataPoint Value="8" />
</igChart:Series.DataPoints>
</igChart:Series>
</igChart:XamChart.Series>
</igChart:XamChart>
Hi Teodor,
Thank you for your post. I was struggling to achieve the same for last 2 days. Luckily came across your post and it solves my problem in a minute.
Thanks,
Ashutosh