I am having a problem getting a pie chart to render where there are only two seriesitems and one of the values is 0.
When a third series is added then it has no problems with one of them having a value of 0
<
telerik:RadHtmlChart
runat
=
"server"
ID
=
"PieChart2"
Width
=
"420"
Transitions
=
"true"
>
<
Appearance
>
<
FillStyle
BackgroundColor
=
"White"
/>
</
Appearance
>
<
ChartTitle
Text="CM Standard > Primary > Patients with No Pending Tasks">
<
Appearance
Align
=
"Center"
BackgroundColor
=
"White"
Position
=
"Top"
/>
</
ChartTitle
>
<
PlotArea
>
<
Appearance
>
<
FillStyle
BackgroundColor
=
"White"
/>
</
Appearance
>
<
Series
>
<
telerik:PieSeries
StartAngle
=
"90"
>
<
LabelsAppearance
Position
=
"Circle"
DataFormatString
=
"{0} %"
/>
<
TooltipsAppearance
DataFormatString
=
"{0} %"
/>
<
Items
>
<
telerik:SeriesItem
BackgroundColor
=
"#ff9900"
Exploded
=
"true"
Name
=
"Internet Explorer"
YValue
=
"18.3"
/>
<
telerik:SeriesItem
BackgroundColor
=
"#cccccc"
Exploded
=
"false"
Name
=
"Firefox"
YValue
=
"35.8"
/>
<%--<
telerik:SeriesItem
BackgroundColor
=
"#bbbbbb"
Exploded
=
"false"
Name
=
"Firefox"
YValue
=
"35.8"
/>--%>
</
Items
>
</
telerik:PieSeries
>
</
Series
>
</
PlotArea
>
<
Legend
>
<
Appearance
BackgroundColor
=
"White"
Position
=
"Bottom"
Visible
=
"true"
/>
</
Legend
>
</
telerik:RadHtmlChart
>
public void LoadChartData()
{
int totalpatients = Utilities.GetInt(ds.Tables[0].Rows[0]["TotalPatients"]);
int PatientsNoPendingTasks = Utilities.GetInt(ds.Tables[0].Rows[0]["PatientsNoPendingTasks"]);
int PatientsWithPendingTasks = Utilities.GetInt(ds.Tables[0].Rows[0]["PatientsWithPendingTasks"]);
int PatientsOverDueforCHA = Utilities.GetInt(ds.Tables[0].Rows[0]["PatientsOverDueforCHA"]);
int PatientsWithUpdatedCHA = totalpatients - PatientsOverDueforCHA;
PieSeries pieSeries = (PieSeries)PieChart2.PlotArea.Series[0];
PieChart2.PlotArea.Series[0].Items[0].Name = "No Pending Tasks";
PieChart2.PlotArea.Series[0].Items[0].YValue = 0;// PatientsNoPendingTasks;
PieChart2.PlotArea.Series[0].Items[1].YValue = 43;// PatientsNoPendingTasks;
PieChart2.PlotArea.Series[0].Items[1].Name = "Has Pending Tasks";
//PieChart2.PlotArea.Series[0].Items[2].YValue = 10;// PatientsNoPendingTasks;
//PieChart2.PlotArea.Series[0].Items[2].Name = "Test";
}