Area Chart
Output: AddAreaChart.xlsx
var workbook = new Workbook();
var dataSheet = workbook.Worksheets[0];
dataSheet.Name = "Data";
dataSheet.GetRange("A1:D1").SetColumnsWidthPixel(110);
dataSheet.GetRange("B1:D1").SetValue(new[] { "Series 1", "Series 2", "Series 3" });
dataSheet.GetRange("A2:A5").SetValue(new[] { "Point 1", "Point 2", "Point 3", "Point 4" });
dataSheet.GetRange("B2:B5").SetValue(new[] { 2, 4, 6, 8 });
dataSheet.GetRange("C2:C5").SetValue(new[] { 4, 3, 2, 1 });
dataSheet.GetRange("D2:D5").SetValue(new[] { 2, 1, -1, -2 });
var worksheet = workbook.AddWorksheet("2-D Area");
var cellOffset = new PointDoubleUnit(19050, 19050, ScreenMeasurementUnit.Emu);
worksheet.GetRange("A1:A4").SetRowsHeight(66);
worksheet.GetRange("A8:A11").SetRowsHeight(66);
var chart1 = worksheet.Charts.AddAreaChart(2, "Chart 1", "A1", cellOffset);
chart1.Size.HeightInches = 2.5;
chart1.Size.WidthInches = 3.5;
chart1.DataSource = "Data!$A$1:$D$5";
var chart2 = worksheet.Charts.AddAreaChart(3, "Chart 2", "A7", cellOffset);
chart2.Size.HeightInches = 2.5;
chart2.Size.WidthInches = 3.5;
chart2.Grouping = Grouping.Stacked;
chart2.DataSource = "Data!$A$1:$D$5";
workbook.SaveAs("AddAreaChart.xlsx");