I have a chart that is getting data from a SQL database in codebehind. Everything displays correctly and the series have the correct number on hover.
It is a stacked bar with the Show totals work a round found on this site.
I know the data coming from SQL is a number because I'm casting it to decimal.
The gTotal shows: "TL bbl: NaN"
Any Ideas?
code behind:
Dim daFMChart As New SqlDataAdapter(SQLFM, Conn)
daFMChart.Fill(DTFMChart)
Me.ColumnChart.DataSource = DTFMChart
Me.ColumnChart.DataBind()
The SQL data is this:
DateTime TotalRed TotalWhite gTotal2016-03-25 20000 3 0.00012016-03-24 30000 2601 0.00012016-03-23 50000 45626 0.00012016-03-22 10000 55568 0.00012016-03-21 30000 54098 0.00012016-03-20 10000 51351 0.00012016-03-19 20000 21973 0.0001
<telerik:RadHtmlChart runat="server" ID="ColumnChart" Transitions="true" Skin="Silk" Visible="false" Style="width: 100%; height: 100%;"> <ChartTitle Text="Daily Volume Total Per Meter"> <Appearance Align="Right" Position="Top"> <TextStyle Color="#999999" /> </Appearance> </ChartTitle> <Legend> <Appearance Position="Right" Visible="true"> <TextStyle Color="#999999" /> </Appearance> </Legend> <PlotArea> <Series> <telerik:ColumnSeries Name="FM Red" DataFieldY="TotalRed" Stacked="true"> <LabelsAppearance Visible="false"></LabelsAppearance> <Appearance> <FillStyle BackgroundColor="#ff1a1a"></FillStyle> </Appearance> </telerik:ColumnSeries> <telerik:ColumnSeries Name="FM White" DataFieldY="TotalWhite"> <LabelsAppearance Visible="false"></LabelsAppearance> <Appearance> <FillStyle BackgroundColor="#bfbfbf"></FillStyle> </Appearance> </telerik:ColumnSeries> <telerik:ColumnSeries DataFieldY="gTotal" Stacked="true"> <Appearance FillStyle-BackgroundColor="#DDD9C3"></Appearance> <LabelsAppearance Position="OutsideEnd"> <TextStyle Color="#999999" /> <TextStyle Margin="0" /> <ClientTemplate> TL bbls: #=dataItem.TotalRed + dataItem.TotalWhite# </ClientTemplate> </LabelsAppearance> <TooltipsAppearance Visible="false"> </TooltipsAppearance> </telerik:ColumnSeries> </Series> <XAxis DataLabelsField="DateTime"></XAxis> <XAxis> <MajorGridLines Visible="false" /> <MinorGridLines Visible="false" /> <LabelsAppearance Step="1"> <TextStyle Color="#999999" /> </LabelsAppearance> </XAxis> <YAxis> <MajorGridLines Visible="true" Color="#555555" /> <MinorGridLines Visible="false" /> <LabelsAppearance Step="1"> <TextStyle Color="#999999" /> </LabelsAppearance> </YAxis> </PlotArea> <ChartTitle Text=""></ChartTitle></telerik:RadHtmlChart>