@section ContentSection
{
<div>
@{Html.EJ().Tab("defaultTabs").Items(data =>
{
data.Add().ID("year").Text("Year Sales").ContentTemplate(@<div>
@{Html.EJ().Chart("chartYear")
.PrimaryXAxis(xAxis => xAxis.ValueType(AxisValueType.Category))
.PrimaryYAxis(yAxis => yAxis.ValueType(AxisValueType.Double)
.LabelFormat("$ {value}")
.Range(range => range.Min(0).Max(300).Interval(50)))
.Series(sr =>
{
sr.Name("2014 Sales")
.Type(SeriesType.Column)
.DataSource((System.Collections.IEnumerable)ViewBag.datasourceYear)
.XName("Xmonth")
.YName("Sales")
.YAxisName("Sales").Add();
})
.Render();}
</div>);
data.Add().ID("month").Text("Month Sales").ContentTemplate(@<div>
@{Html.EJ().Chart("chartMonth")
.PrimaryXAxis(xAxis => xAxis.ValueType(AxisValueType.Category))
.PrimaryYAxis(yAxis => yAxis.ValueType(AxisValueType.Double)
.LabelFormat("$ {value}")
.Range(range => range.Min(0).Max(300).Interval(50)))
.Series(sr =>
{
sr.Name("November Sales")
.Type(SeriesType.Column)
.DataSource((System.Collections.IEnumerable)ViewBag.datasourceMonth)
.XName("Xmonth")
.YName("Sales")
.YAxisName("Sales").Add();
})
.Render();}
</div>);
}).Render();}
}
The chart on the first tab displays just fine but when I click to the second tab the chart is not displayed. I verified the chart is working properly by putting both charts on the same page.
What do I need to do in order for the chart on the second tab to display correctly.
Hi Fabio,
Thanks for using syncfusion product. We
have analyzed the reported issue with our sample; we are not able to reproduce
the issue. Can you please check with the attached sample.
If still you face the problem, please revert us by modifying the sample
based on your application along with replication procedure. This would be
helpful for us to serve you.
Please let us know if you have any concern.
Regards,
Akbar Basha KM.