Spread Windows Forms 11.0 Product Documentation
Fill Property (BoxWhiskerSeries)
Example 


FarPoint.Win.Chart Assembly > FarPoint.Win.Chart Namespace > BoxWhiskerSeries Class : Fill Property
Gets or sets the fill for the surface.
Syntax
'Declaration
 
Public Property Fill As Fill
'Usage
 
Dim instance As BoxWhiskerSeries
Dim value As Fill
 
instance.Fill = value
 
value = instance.Fill
public Fill Fill {get; set;}
Remarks
Value of null (Nothing in VB) indicates that the fill is unset for the surface.
Example
This example creates a box whisker chart.
FarPoint.Win.Chart.BoxWhiskerSeries series1 = new FarPoint.Win.Chart.BoxWhiskerSeries();
series1.SeriesName = "Store1";
series1.CategoryNames.AddRange(new string[] {"Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss" });
series1.Values.Add(20);
series1.Values.Add(25);
series1.Values.Add(21);
series1.Values.Add(30);
series1.Values.Add(10);
series1.Values.Add(26);
series1.Values.Add(18);
series1.Values.Add(28);
series1.Values.Add(12);
series1.Values.Add(20);
series1.Values.Add(17);
series1.Values.Add(35);           
series1.Border = new FarPoint.Win.Chart.SolidLine(Color.Black);
series1.Fill = new FarPoint.Win.Chart.GradientFill(Color.Brown, Color.Orange);
FarPoint.Win.Chart.BoxWhiskerSeries series2 = new FarPoint.Win.Chart.BoxWhiskerSeries();
series2.SeriesName = "Store2";
series2.CategoryNames.AddRange(new string[] { "Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss" });
series2.Values.Add(15);
series2.Values.Add(18);
series2.Values.Add(19);
series2.Values.Add(22);
series2.Values.Add(10);
series2.Values.Add(19);
series2.Values.Add(15);
series2.Values.Add(25);
series2.Values.Add(14);
series2.Values.Add(19);
series2.Values.Add(16);
series2.Values.Add(24);
series2.Border = new FarPoint.Win.Chart.SolidLine(Color.Black);
series2.Fill = new FarPoint.Win.Chart.GradientFill(Color.Lavender, Color.DeepSkyBlue);
FarPoint.Win.Chart.BoxWhiskerSeries series3 = new FarPoint.Win.Chart.BoxWhiskerSeries();
series3.SeriesName = "Store3";
series3.CategoryNames.AddRange(new string[] { "Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss" });
series3.Values.Add(5);
series3.Values.Add(12);
series3.Values.Add(20);
series3.Values.Add(25);
series3.Values.Add(8);
series3.Values.Add(10);
series3.Values.Add(11);
series3.Values.Add(22);
series3.Values.Add(13);
series3.Values.Add(12);
series3.Values.Add(15);
series3.Values.Add(21);
FarPoint.Win.Chart.ClusteredBoxWhiskerSeries cseries = new FarPoint.Win.Chart.ClusteredBoxWhiskerSeries();
cseries.Series.Add(series1);
cseries.Series.Add(series2);
cseries.Series.Add(series3);
FarPoint.Win.Chart.YPlotArea plotArea = new FarPoint.Win.Chart.YPlotArea();
plotArea.Series.Add(cseries);
FarPoint.Win.Chart.LegendArea legend = new FarPoint.Win.Chart.LegendArea();
legend.Location = new PointF(0.80F, 0.5F);
FarPoint.Win.Chart.ChartModel model = new FarPoint.Win.Chart.ChartModel();
model.PlotAreas.Add(plotArea);
model.LegendAreas.Add(legend);
FarPoint.Win.Spread.Chart.SpreadChart chart = new FarPoint.Win.Spread.Chart.SpreadChart();
chart.Size = new Size(400, 400);
chart.Model = model;
fpSpread1.Sheets[0].Charts.Add(chart);
Dim series1 As New FarPoint.Win.Chart.BoxWhiskerSeries()
series1.SeriesName = "Store1"
series1.CategoryNames.AddRange(New String() {"Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss"})
series1.Values.Add(20)
series1.Values.Add(25)
series1.Values.Add(21)
series1.Values.Add(30)
series1.Values.Add(10)
series1.Values.Add(26)
series1.Values.Add(18)
series1.Values.Add(28)
series1.Values.Add(12)
series1.Values.Add(20)
series1.Values.Add(17)
series1.Values.Add(35)
series1.Border = New FarPoint.Win.Chart.SolidLine(Color.Black)
series1.Fill = New FarPoint.Win.Chart.GradientFill(Color.Brown, Color.Orange)
Dim series2 As New FarPoint.Win.Chart.BoxWhiskerSeries()
series2.SeriesName = "Store2"
series2.CategoryNames.AddRange(New String() {"Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss"})
series2.Values.Add(15)
series2.Values.Add(18)
series2.Values.Add(19)
series2.Values.Add(22)
series2.Values.Add(10)
series2.Values.Add(19)
series2.Values.Add(15)
series2.Values.Add(25)
series2.Values.Add(14)
series2.Values.Add(19)
series2.Values.Add(16)
series2.Values.Add(24)
series2.Border = New FarPoint.Win.Chart.SolidLine(Color.Black)
series2.Fill = New FarPoint.Win.Chart.GradientFill(Color.Lavender, Color.DeepSkyBlue)
Dim series3 As New FarPoint.Win.Chart.BoxWhiskerSeries()
series3.SeriesName = "Store3"
series3.CategoryNames.AddRange(New String() {"Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss", "Asiago", "Gouda", "Havarti", "Swiss"})
series3.Values.Add(5)
series3.Values.Add(12)
series3.Values.Add(20)
series3.Values.Add(25)
series3.Values.Add(8)
series3.Values.Add(10)
series3.Values.Add(11)
series3.Values.Add(22)
series3.Values.Add(13)
series3.Values.Add(12)
series3.Values.Add(15)
series3.Values.Add(21)
Dim cseries As New FarPoint.Win.Chart.ClusteredBoxWhiskerSeries()
cseries.Series.Add(series1)
cseries.Series.Add(series2)
cseries.Series.Add(series3)
Dim plotArea As New FarPoint.Win.Chart.YPlotArea()
plotArea.Series.Add(cseries)
Dim legend As New FarPoint.Win.Chart.LegendArea()
legend.Location = New PointF(0.8F, 0.5F)
Dim model As New FarPoint.Win.Chart.ChartModel()
model.PlotAreas.Add(plotArea)
model.LegendAreas.Add(legend)
Dim chart As New FarPoint.Win.Spread.Chart.SpreadChart()
chart.Size = New Size(400, 400)
chart.Model = model
FpSpread1.Sheets(0).Charts.Add(chart)
See Also

Reference

BoxWhiskerSeries Class
BoxWhiskerSeries Members