AddBarChart Method

The AddBarChart method adds a 2D bar chart to an existing 2D graph, equivalent to Graph | Add to Graph | Plot. Returns an AutoBarChart object.

Syntax

object.AddBarChart( worksheet, xCol, yCol, xAxis, yAxis, id )

 

Parameter Type Description
worksheet String required, the full path and file name of the data
xCol Variant optional, default = 1 (column A)
yCol Variant optional, default = 2 (column B)
id Variant optional, chart name

 

Remarks

2D graphs can only be added to other 2D graphs.

Example

This example shows how to add a bar chart.

Graph1.AddBarChart(GrapherApp.Path + "\samples\bar chart orientations.dat")

 

Used by: AutoGraph object

See Also

AddBarChartGraph