We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Make IsVisible a bindable property on a tertiary YAxis NumericalAxis?

I was happy to see that although it doesn't appear to be documented SfChart on Xamarin Forms mostly supports the following:

            <chart:LineSeries x:Name="MyChart" XBindingPath="MyDate" YBindingPath="MyDouble" ItemsSource="{Binding MyData}" Color="Blue" StrokeWidth="5" IsVisible="{Binding LineSeriesVisiblity}">
                    <chart:NumericalAxis Minimum="0" Maximum="120" ShowMajorGridLines="False"  OpposedPosition="True" TickPosition="Outside" IsVisible="{Binding LineSeriesVisiblity}">
                        <chart:ChartAxisLabelStyle TextColor="{StaticResource WeFeelDarkBlue}">

What doesn't work is the binding for IsVisible="{Binding LineSeriesVisiblity}" on the <chart:NumericalAxis.... line in order to hide the YAxis with its labels as needed.  

The use case is this particular series has a much different minimum and maximum, and the user has the option to hide the series itself via a button which toggles the LineSeriesVisiblity to false.  That part works fine, but we also want to had the actually axis on the right since we aren't showing the data, and without the data the Axis makes the chart confusing. This works on WinRT.   I can just set IsVisible to False in the XAML instead of using a binding and that actually will hide the axis.  It seems like IsVisible either isn't backed by a bindable property, or some how the property changed event isn't being picked up when I change LineSeriesVisiblity from the view model.

Any workarounds for this?

2 Replies

ME Manivannan Elangovan Syncfusion Team November 26, 2015 01:07 PM UTC

Hi Jeff,

We have logged a defect report for the reported issue "BindingContext is not working for YAxis" and the fix for the issue is estimated to be available in our Volume 3 Service Pack 2 release, which is scheduled to roll out by the end of this month.


ME Manivannan Elangovan Syncfusion Team December 1, 2015 11:19 AM UTC

Hi Jeff,

We are glad to announce that our Essential Studio service pack 2 for Volume 3, 2015 is rolled out and is available for download under the following link:


We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.

Manivannan E

Live Chat Icon For mobile
Up arrow icon