// Define user command methods. public void AddNewItemButton_Click(object sender, EventArgs e) { var item = new ScheduleChartItem { Content = "New resource", GanttChartItems = new List <GanttChartItem> { new GanttChartItem { Content = "Task X (New resource)", Start = new DateTime(year, month, 2, 8, 0, 0), Finish = new DateTime(year, month, 5, 16, 0, 0) }, new GanttChartItem { Content = "Task Y (New resource)", Start = new DateTime(year, month, 7, 8, 0, 0), Finish = new DateTime(year, month, 8, 16, 0, 0) } } }; ScheduleChartView.AddItem(item); ScheduleChartView.SelectedItem = item; ScheduleChartView.ScrollTo(item); ScheduleChartView.ScrollTo(new DateTime(year, month, 1)); }