SeriesList sList = new SeriesList();
sList.SeriesCollection.Add(new Series());
sList.ChartType = ChartType.Gantt;
sList.AxisFactor.YAxis.DataType = AxisDataType.DateTime;
sList.AxisFactor.YAxis.Interval = 10;
sList.AxisFactor.Orientation = AxisOrientation.TopLeft;
for(int i = 0; i < 5; i++)
{
sList.SeriesCollection[0].items.Add(new SeriesItem());
sList.SeriesCollection[0].items[i].IsShowFigureText = true;
}
sList.Gantt.DateType = DateType.Time;
sList.Gantt.Suffix = "분간";
sList.AxisFactor.YAxis.DateTimeFormat = "HH:mm";
sList.AxisFactor.YAxis.Interval = 60;
sList.AxisFactor.YAxis.IsAutoSetting = false;
sList.AxisFactor.YAxis.MinUnitDateTimeValue = new DateTime(2009, 1, 10, 2, 0, 0);
sList.AxisFactor.YAxis.MaxUnitDateTimeValue = new DateTime(2009, 1, 10, 15, 0, 0);
sList.SeriesCollection[0].items[0].YStartDateTimeValue = new DateTime(2009, 1, 10, 2, 30, 0);
sList.SeriesCollection[0].items[0].YDateTimeValue = new DateTime(2009, 1, 10, 8, 0, 0);
sList.SeriesCollection[0].items[1].YStartDateTimeValue = new DateTime(2009, 1, 10, 4, 0, 0);
sList.SeriesCollection[0].items[1].YDateTimeValue = new DateTime(2009, 1, 10, 5, 0, 0);
sList.SeriesCollection[0].items[2].YStartDateTimeValue = new DateTime(2009, 1, 10, 11, 55, 0);
sList.SeriesCollection[0].items[2].YDateTimeValue = new DateTime(2009, 1, 10, 14, 0, 0);
sList.SeriesCollection[0].items[3].YStartDateTimeValue = new DateTime(2009, 1, 10, 5, 0, 0);
sList.SeriesCollection[0].items[3].YDateTimeValue = new DateTime(2009, 1, 10, 9, 0, 0);
sList.SeriesCollection[0].items[4].YStartDateTimeValue = new DateTime(2009, 1, 10, 11, 0, 0);
sList.SeriesCollection[0].items[4].YDateTimeValue = new DateTime(2009, 1, 10, 13, 30, 0);
sList.SeriesCollection[0].items[0].Name = "수면 시간";
sList.SeriesCollection[0].items[1].Name = "자유 시간";
sList.SeriesCollection[0].items[2].Name = "공부좀 합시다";
sList.SeriesCollection[0].items[3].Name = "밥먹기";
sList.SeriesCollection[0].items[4].Name = "여친과 데이트";
Palette p = new Palette();
sList.SeriesCollection[0].items[0].ItemColor = p.DefaultColor1;
sList.SeriesCollection[0].items[1].ItemColor = p.DefaultColor2;
sList.SeriesCollection[0].items[2].ItemColor = p.DefaultColor3;
sList.SeriesCollection[0].items[3].ItemColor = p.DefaultColor4;
sList.SeriesCollection[0].items[4].ItemColor = p.DefaultColor5;
this.hHippoChart1.SeriesListDictionary.Add(sList);
this.hHippoChart1.LegendBox.Visible = false;
this.hHippoChart1.DrawChart();
Dim sList As New. SeriesList()
sList.SeriesCollection.Add(New Series())
sList.ChartType = ChartType.Gantt
sList.AxisFactor.YAxis.DataType = AxisDataType.DateTime
sList.AxisFactor.YAxis.Interval = 10
sList.AxisFactor.Orientation = AxisOrientation.TopLeft
Dim i As Integer = 0
While i < 5
sList.SeriesCollection(0).items.Add(New SeriesItem())
sList.SeriesCollection(0).items(i).IsShowFigureText = True
System.Math.Max(System.Threading.Interlocked.Increment(i),i - 1)
End While
sList.Gantt.DateType = DateType.Time
sList.Gantt.Suffix = "분간"
sList.AxisFactor.YAxis.DateTimeFormat = "HH:mm"
sList.AxisFactor.YAxis.Interval = 60
sList.AxisFactor.YAxis.IsAutoSetting = False
sList.AxisFactor.YAxis.MinUnitDateTimeValue = New DateTime(2009, 1, 10, 2, 0, 0)
sList.AxisFactor.YAxis.MaxUnitDateTimeValue = New DateTime(2009, 1, 10, 15, 0, 0)
sList.SeriesCollection(0).items(0).YStartDateTimeValue = New DateTime(2009, 1, 10, 2, 30, 0)
sList.SeriesCollection(0).items(0).YDateTimeValue = New DateTime(2009, 1, 10, 8, 0, 0)
sList.SeriesCollection(0).items(1).YStartDateTimeValue = New DateTime(2009, 1, 10, 4, 0, 0)
sList.SeriesCollection(0).items(1).YDateTimeValue = New DateTime(2009, 1, 10, 5, 0, 0)
sList.SeriesCollection(0).items(2).YStartDateTimeValue = New DateTime(2009, 1, 10, 11, 55, 0)
sList.SeriesCollection(0).items(2).YDateTimeValue = New DateTime(2009, 1, 10, 14, 0, 0)
sList.SeriesCollection(0).items(3).YStartDateTimeValue = New DateTime(2009, 1, 10, 5, 0, 0)
sList.SeriesCollection(0).items(3).YDateTimeValue = New DateTime(2009, 1, 10, 9, 0, 0)
sList.SeriesCollection(0).items(4).YStartDateTimeValue = New DateTime(2009, 1, 10, 11, 0, 0)
sList.SeriesCollection(0).items(4).YDateTimeValue = New DateTime(2009, 1, 10, 13, 30, 0)
sList.SeriesCollection(0).items(0).Name = "수면 시간"
sList.SeriesCollection(0).items(1).Name = "자유 시간"
sList.SeriesCollection(0).items(2).Name = "공부좀 합시다"
sList.SeriesCollection(0).items(3).Name = "밥먹기"
sList.SeriesCollection(0).items(4).Name = "여친과 데이트"
Dim p As New. Palette()
sList.SeriesCollection(0).items(0).ItemColor = p.DefaultColor1
sList.SeriesCollection(0).items(1).ItemColor = p.DefaultColor2
sList.SeriesCollection(0).items(2).ItemColor = p.DefaultColor3
sList.SeriesCollection(0).items(3).ItemColor = p.DefaultColor4
sList.SeriesCollection(0).items(4).ItemColor = p.DefaultColor5
Me.hHippoChart1.SeriesListDictionary.Add(sList)
Me.hHippoChart1.LegendBox.Visible = False
Me.hHippoChart1.DrawChart()