Is there way to add data trigger to XamChart, when value = 0, marker will become invisible or use transparent fill. Label will still be displayed.
Thanks!
----------------------------------------------------------------------------------------------------------------
<Style x:Key="NoLabelMarker" TargetType="{x:Type igCA:Marker}"> <Setter Property="Fill" Value="Black"/> <Setter Property="Stroke" Value="Black"/> <Setter Property="MarkerSize" Value=".5"/> <Setter Property="Foreground" Value="Transparent"/> </Style>
<igCA:XamChart Name="ColumnChart2D" Style="{StaticResource XamChartStyle}" Grid.Row="1" > <igCA:XamChart.Legend> <igCA:Legend Visible="False"/> </igCA:XamChart.Legend>
<!-- Data points --> <igCA:XamChart.Series>
<igCA:Series Label="Goal" x:Name="goalSeries" ChartType="line" StrokeThickness="0" Fill="#FFD70005"> <igCA:Series.DataPoints> <igCA:DataPoint Value="0" Label="A1"/> <igCA:DataPoint Value="0.8" Label="A2"/> <igCA:DataPoint Value="0.85" Label="A3"/> <igCA:DataPoint Value="0.95" Label="A4"/> <igCA:DataPoint Value="1.0" Label="A5"/> </igCA:Series.DataPoints> <igCA:Series.Marker> <igCA:Marker Style="{StaticResource NoLabelMarker}"/> </igCA:Series.Marker></igCA:Series>
</igCA:XamChart>
Hello Lily,
Thank you for your feedback. I am glad that you resolved your issue and I believe that other community members may benefit from this as well.
Thanks again.
that did the trick. Thank you!!!
Hello again,
There should be space between quote like this Format =" ".
Hope this helps you.
i added Format = "", the value of datapoint is still being displayed:
<igCA:Series.Marker> <igCA:Marker UseDataTemplate="True" DataTemplate="{StaticResource dt}" Format=""/> </igCA:Series.Marker>
Thanks again for your help!
I am glad I helped you. As for the Marker’s Value you can set the Marker’s Format Property to “ “ (empty space) in order to achieve your goal. Please let me know if this helps you or you need further assistance on this matter.
Looking forward for your reply.