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

Can't set Intervals in xaml

Trying to set intervals in xaml but am getting the error "Only public or internal classes can be used within markup. 'Interval' type is not public or internal.".
Am I missing something? - pulled implementation from an example.


                    <chart:SfDateTimeRangeNavigator x:Name="RangeNavigator"
                                            Minimum="2015/5/18" Maximum="2015/5/18"
                                            ViewRangeStart="2015/5/18" ViewRangeEnd="2015/5/19"
                                            ShowGridLines="True" ShowToolTip="True"
                                            ItemsSource="{Binding StockPriceDetails}" XBindingPath="_Date" Height="179">

                        <chart:SfDateTimeRangeNavigator.Intervals>
                            <chart:Interval IntervalType="Quarter"/>
                            <chart:Interval IntervalType="Month"/>
                        </chart:SfDateTimeRangeNavigator.Intervals>

                        <chart:SfDateTimeRangeNavigator.Content>




3 Replies

SA Santhiya Arulsamy Syncfusion Team October 27, 2016 09:25 AM UTC

Hi Alan,

Thanks for contacting Syncfusion Support.

We are unable to reproduce the reported problem. We have prepared a sample based on requirement and it can be downloaded from below link,

Sample: SfRangeNavigator_127112

If you are able to reproduce the reported problem, please revert us by modifying the sample. It would be helpful for us to sever you better.

Thanks,
Santhiya A


AL Alan L October 27, 2016 02:59 PM UTC

The difference between our two solutions that make it work or fail...

My solution: (produces error)
        xmlns:chart="http://schemas.syncfusion.com/wpf"

Your solution: (good to go)
        xmlns:chart="clr-namespace:Syncfusion.UI.Xaml.Charts;assembly=Syncfusion.SfChart.WPF"

I have been experimenting a lot with examples from online and must have an unhappy mishmash of code.

Thank you,
Alan


SS Sheik Syed Abthaheer M Syncfusion Team October 28, 2016 07:30 AM UTC

Hi Alan,

Sorry for the inconvenience caused.

Most Syncfusion WPF controls( SfChart,SfDataGrid,SfDateTimeRangeNavigator etc. ) namespace are included in single http://schemas.syncfusion.com/wpf schemas and we can access those controls from this namespace. In order to access SfDateTimeRangeNavigator control, we can use either “clr-namespace:Syncfusion.UI.Xaml.Charts;assembly=Syncfusion.SfChart.WPF" or “http://schemas.syncfusion.com/wpf”.

In updated sample, we are unable to reproduce the issue in both namespace at our end. Also please refer the below UG documents for creating the SfDateTimeRangeNavigator control sample.

https://help.syncfusion.com/wpf/sfdatetimerangenavigator/getting-started  

Regards,
M. Sheik


 


Loader.
Live Chat Icon For mobile
Up arrow icon