Bar

Add chart method present in slide component or you can replace the chart using shape componenet.

Basic Code Sample

// Bare minimum
powerPoint.AddSlide(PresentationConstants.SlideLayoutType.BLANK)
	.AddChart(CreateDataCellPayload(), new G.BarChartSetting());
// Some additional samples
powerPoint.AddSlide(PresentationConstants.SlideLayoutType.BLANK)
	.AddChart(CreateDataCellPayload(), new G.BarChartSetting()
	{
		chartAxesOptions = new()
		{
			isHorizontalAxesEnabled = false,
		},
		barChartDataLabel = new G.BarChartDataLabel()
		{
			dataLabelPosition = G.BarChartDataLabel.DataLabelPositionValues.INSIDE_END,
			showValue = true,
		},
		barChartSeriesSettings = new(){
			new(),
			new(){
				barChartDataLabel = new G.BarChartDataLabel(){
					dataLabelPosition = G.BarChartDataLabel.DataLabelPositionValues.OUTSIDE_END,
					showCategoryName= true
				}
			}
		}
	});

BarChartSetting Options

Contains options details extended from ChartSetting that are specific to bar chart.

BarChartDataLabel Options

Contains options details extended from ChartDataLabel that are specific to bar chart.

barChartSeriesSetting Options

Contains options details extended from ChartSeriesSetting that are specific to bar chart.

BarGraphicsSetting Options only applied in cluster type

BarChartDataPointSetting Options

Contains options details extended from ChartDataPointSetting that are specific to bar chart.

Last updated