Left Property

Applies To

Application object, Axis object, AxisTitle object, ChartArea object, ChartObject object, ChartObjects collection object, ChartTitle object, DataLabel object, Legend object, LegendEntry object, LegendKey object, OLEObject object, OLEObjects collection object, PlotArea object, Range object, Shape object, ShapeRange collection object, Window object.

Description

Returns or sets the position of the specified object, in points. Read/write Long, except as shown in the following table.

Remarks

The meaning of the Left property depends on the specified object.

Object

Meaning

Application

The distance from the left edge of the screen to the left edge of the main Microsoft Excel window.

Axis, LegendEntry, LegendKey

The distance from the left edge of the object to the left edge of the chart area. Read-only.

Range

The distance from the left edge of column A to the left edge of the range. If the range is discontinuous, the first area is used. If the range is more than one column wide, the leftmost column in the range is used. Read-only.

Window

The distance from the left edge of the client area to the left edge of the window.

AxisTitle, ChartArea, ChartTitle, DataLabel, Legend, OLEObject, PlotArea, Shape, ShapeRange

The distance from the left edge of the object to the left edge of column A (on a worksheet) or the left edge of the chart area (on a chart).


If the window is maximized, Application.Left returns a negative number that varies based on the width of the window border. Setting Application.Left to 0 (zero) will make the window a tiny bit smaller than it would be if the application window were maximized. In other words, if Application.Left is 0 (zero), the left border of the main Microsoft Excel window will just barely be visible on the screen.

On the Macintosh, Application.Left is always 0 (zero). Setting this value to something else on the Macintosh will have no effect.

In Windows, if the Microsoft Excel window is minimized, Application.Left controls the position of the window icon.

See Also

Height property, Top property, Width property.

Example

This example aligns the left edge of the embedded chart with the left edge of column B.

With Worksheets("Sheet1")
    .ChartObjects(1).Left = .Columns("B").Left
End With