SeriesList sList = new SeriesList();
sList.ChartType = ChartType.Column;
sList.AxisFactor.AxisItems.Add(new Axis(AxisType.Ytype));
sList.AxisFactor.AxisItems.Add(new Axis(AxisType.Ytype));
sList.AxisFactor.YAxis.SetAxisStep(0, 150, 25);
Random r = new Random();
for(int i = 0; i < 3; i++)
{
Series sr = new Series();
sr.AxisIndex = i;
if (i == 1)
{
sr.ChartType = ChartType.Spline;
sr.Points.Width = 10;
sr.Line.LineWidth = 2;
}
if (i == 2)
{
sr.ChartType = ChartType.Line;
sr.Points.Width = 10;
sr.Line.LineWidth = 2;
sr.Points.PointType = PointType.FillRectangle;
}
for(int x = 0; x < 6; x++)
{
SeriesItem item = new SeriesItem();
item.Name = "item" + x.ToString();
item.YValue = r.Next(99);
if (i == 1)
{
item.YValue = r.Next(13454);
}
if (i == 2)
{
item.YValue = r.Next(77778787);
}
sr.items.Add(item);
}
sList.SeriesCollection.Add(sr);
}
this.hHippoChart1.DesignType = ChartDesignType.Simple2;
this.hHippoChart1.PaletteType = PaletteType.Soft;
this.hHippoChart1.SeriesListDictionary.Add(sList);
this.hHippoChart1.DrawChart();
Dim sList As New. SeriesList()
sList.ChartType = ChartType.Column
sList.AxisFactor.AxisItems.Add(New Axis(AxisType.Ytype))
sList.AxisFactor.AxisItems.Add(New Axis(AxisType.Ytype))
sList.AxisFactor.YAxis.SetAxisStep(0, 150, 25)
Dim r As New. Random()
For i As Integer = 0 To 2
Dim sr As New. Series()
sr.AxisIndex = i
If i = 1 Then
sr.ChartType = ChartType.Spline
sr.Points.Width = 10
sr.Line.LineWidth = 2
End If
If i = 2 Then
sr.ChartType = ChartType.Line
sr.Points.Width = 10
sr.Line.LineWidth = 2
sr.Points.PointType = PointType.FillRectangle
End If
For x As Integer = 0 To 5
Dim item As New. SeriesItem()
item.Name = "item" & x.ToString()
item.YValue = r.[Next](99)
If i = 1 Then
item.YValue = r.[Next](13454)
End If
If i = 2 Then
item.YValue = r.[Next](77778787)
End If
sr.items.Add(item)
Next
sList.SeriesCollection.Add(sr)
Next
Me.hHippoChart1.DesignType = ChartDesignType.Simple2
Me.hHippoChart1.PaletteType = PaletteType.Soft
Me.hHippoChart1.SeriesListDictionary.Add(sList)
Me.hHippoChart1.DrawChart()