Download QCChart2D CF Charting Library for the .Net Compact Framework

Transcript
274 Group Plot Objects
new Background( pTransform1, ChartObj.GRAPH_BACKGROUND,
Color.FromArgb(30,70,70), Color.FromArgb(90,20,155),
ChartObj.Y_AXIS);
chartVu.AddChartObject(graphbackground);
Background plotbackground = new Background( pTransform1,
ChartObj.PLOT_BACKGROUND, Color.Black);
chartVu.AddChartObject(plotbackground);
.
.
// Define axes, axes labels and grids
.
ChartAttribute attrib1 =
new ChartAttribute (Color.Black, 0,DashStyle.Solid, Color.Green);
attrib1.SetFillFlag(true);
HistogramPlot thePlot1 = new HistogramPlot(pTransform1, Dataset1, 0.0, attrib1);
NumericLabel bardatavalue = thePlot1.GetPlotLabelTemplate();
bardatavalue.SetTextFont(theFont);
bardatavalue.SetNumericFormat(ChartObj.PERCENTFORMAT);
bardatavalue.SetColor(Color.Black);
thePlot1.SetBarDatapointLabelPosition(ChartObj.INSIDE_BAR);
thePlot1.SetPlotLabelTemplate(bardatavalue);
thePlot1.SetShowDatapointValue(true);
thePlot1.SetSegmentAttributesMode(true);
thePlot1.SetSegmentFillColor(0,Color.Red);
thePlot1.SetSegmentFillColor(1, Color.Magenta);
thePlot1.SetSegmentFillColor(2, Color.Blue);
thePlot1.SetSegmentFillColor(3, Color.Green);
thePlot1.SetSegmentFillColor(4, Color.Yellow);
thePlot1.SetSegmentFillColor(5, Color.Pink);
chartVu.AddChartObject(thePlot1);
[Visual Basic]
Dim Dataset1 As New GroupDataset("Actual Sales", x1, y1)
Dim pTransform1 As New CartesianCoordinates()
pTransform1.SetScaleStartY(0)
pTransform1.SetScaleStartX(0)
pTransform1.SetScaleStopX(80)
pTransform1.SetScaleStopY(1.0)