Syntax

expression.ErrorBar(Direction, Include, Type, Amount, MinusValues)

expression A variable that represents a Series object.

Parameters

Name Required/Optional Data Type Description
Direction Required The error bar direction.
Include Required The error bar parts to include.
Type Required The error bar type.
Amount Optional Variant The error amount. Used for only the positive error amount when Type is xlErrorBarTypeCustom.
MinusValues Optional Variant The negative error amount when Type is xlErrorBarTypeCustom.

Return Value
Variant

Example

This example applies standard error bars in the Y direction for series one in Chart1. The error bars are applied in the positive and negative directions. The example should be run on a 2-D line chart.

Visual Basic for Applications
Charts("Chart1").SeriesCollection(1).ErrorBar _ Direction:=xlY, Include:=xlErrorBarIncludeBoth, _ Type:=xlErrorBarTypeStError
error error bar errorbar ErrorBar method

See also: