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

Change Chart type at runtime

Hi i have successfully using chart what i am facing challenge is to change to chart type at run time my code is given below please guide me what i have to do to change chart type.
<chart:SfChart BackgroundColor="White" Grid.Row="1" x:Name="Chart" HorizontalOptions="FillAndExpand" VerticalOptions="FillAndExpand">
<chart:ChartZoomPanBehavior EnablePanning="true" EnableZooming="false" />
<chart:ChartTrackballBehavior ShowLabel="True" ShowLine="True" />
<chart:CategoryAxis LabelPlacement="BetweenTicks">
<chart:ChartAxisLabelStyle TextColor="#0B4940">
<Font FontSize="9" FontAttributes="Bold" />
<chart:NumericalAxis Interval="2" Maximum="110" Minimum="90">
<chart:ChartAxisTickStyle TickSize="7" StrokeColor="#0B4940" StrokeWidth="3" />
<chart:ChartAxisTickStyle TickSize="5" StrokeColor="Green" StrokeWidth="2" />
<chart:ChartAxisTitle Text="Temperature °F" />
<chart:SplineSeries EnableDataPointSelection="true" Color="#0B4940" x:Name="Charts" XBindingPath="XValue" YBindingPath="YValue">
<chart:ChartDataMarker ShowLabel="False" ShowMarker="True" MarkerType="Hexagon" MarkerWidth="5" MarkerHeight="5" MarkerColor="Red" MarkerBorderColor="Red" MarkerBorderWidth="2" />

3 Replies

GM Gobi M Syncfusion Team May 25, 2016 12:18 PM UTC

Hi Atif, 
Thanks for using Syncfusion products. 
We are able achieve your requirement for change chart type in runtime. We have prepared a sample for this and it can be downloaded in the below link. 
Please let us know if you need any further assistance.  
Gobi M 

AT Atif May 26, 2016 03:52 PM UTC

Thanks a lot.

GM Gobi M Syncfusion Team May 27, 2016 09:02 AM UTC

Hi Atif, 
Thanks for the update. 
Please let us know if you have any other queries. 
Gobi M 

Live Chat Icon For mobile
Up arrow icon