ExcelScript.Line interface

Represents a line inside a worksheet. To get the corresponding Shape object, use Line.shape.

Methods

connectBeginShape(shape, connectionSite)

Attaches the beginning of the specified connector to a specified shape.

connectEndShape(shape, connectionSite)

Attaches the end of the specified connector to a specified shape.

disconnectBeginShape()

Detaches the beginning of the specified connector from a shape.

disconnectEndShape()

Detaches the end of the specified connector from a shape.

getBeginArrowheadLength()

Represents the length of the arrowhead at the beginning of the specified line.

getBeginArrowheadStyle()

Represents the style of the arrowhead at the beginning of the specified line.

getBeginArrowheadWidth()

Represents the width of the arrowhead at the beginning of the specified line.

getBeginConnectedShape()

Represents the shape to which the beginning of the specified line is attached.

getBeginConnectedSite()

Represents the connection site to which the beginning of a connector is connected. Returns null when the beginning of the line is not attached to any shape.

getConnectorType()

Represents the connector type for the line.

getEndArrowheadLength()

Represents the length of the arrowhead at the end of the specified line.

getEndArrowheadStyle()

Represents the style of the arrowhead at the end of the specified line.

getEndArrowheadWidth()

Represents the width of the arrowhead at the end of the specified line.

getEndConnectedShape()

Represents the shape to which the end of the specified line is attached.

getEndConnectedSite()

Represents the connection site to which the end of a connector is connected. Returns null when the end of the line is not attached to any shape.

getId()

Specifies the shape identifier.

getIsBeginConnected()

Specifies if the beginning of the specified line is connected to a shape.

getIsEndConnected()

Specifies if the end of the specified line is connected to a shape.

getShape()

Returns the Shape object associated with the line.

setBeginArrowheadLength(beginArrowheadLength)

Represents the length of the arrowhead at the beginning of the specified line.

setBeginArrowheadStyle(beginArrowheadStyle)

Represents the style of the arrowhead at the beginning of the specified line.

setBeginArrowheadWidth(beginArrowheadWidth)

Represents the width of the arrowhead at the beginning of the specified line.

setConnectorType(connectorType)

Represents the connector type for the line.

setEndArrowheadLength(endArrowheadLength)

Represents the length of the arrowhead at the end of the specified line.

setEndArrowheadStyle(endArrowheadStyle)

Represents the style of the arrowhead at the end of the specified line.

setEndArrowheadWidth(endArrowheadWidth)

Represents the width of the arrowhead at the end of the specified line.

Method Details

connectBeginShape(shape, connectionSite)

Attaches the beginning of the specified connector to a specified shape.

connectBeginShape(shape: Shape, connectionSite: number): void;

Parameters

shape
ExcelScript.Shape

The shape to connect.

connectionSite

number

The connection site on the shape to which the beginning of the connector is attached. Must be an integer between 0 (inclusive) and the connection-site count of the specified shape (exclusive).

Returns

void

connectEndShape(shape, connectionSite)

Attaches the end of the specified connector to a specified shape.

connectEndShape(shape: Shape, connectionSite: number): void;

Parameters

shape
ExcelScript.Shape

The shape to connect.

connectionSite

number

The connection site on the shape to which the end of the connector is attached. Must be an integer between 0 (inclusive) and the connection-site count of the specified shape (exclusive).

Returns

void

disconnectBeginShape()

Detaches the beginning of the specified connector from a shape.

disconnectBeginShape(): void;

Returns

void

disconnectEndShape()

Detaches the end of the specified connector from a shape.

disconnectEndShape(): void;

Returns

void

getBeginArrowheadLength()

Represents the length of the arrowhead at the beginning of the specified line.

getBeginArrowheadLength(): ArrowheadLength;

Returns

getBeginArrowheadStyle()

Represents the style of the arrowhead at the beginning of the specified line.

getBeginArrowheadStyle(): ArrowheadStyle;

Returns

getBeginArrowheadWidth()

Represents the width of the arrowhead at the beginning of the specified line.

getBeginArrowheadWidth(): ArrowheadWidth;

Returns

getBeginConnectedShape()

Represents the shape to which the beginning of the specified line is attached.

getBeginConnectedShape(): Shape;

Returns

getBeginConnectedSite()

Represents the connection site to which the beginning of a connector is connected. Returns null when the beginning of the line is not attached to any shape.

getBeginConnectedSite(): number;

Returns

number

getConnectorType()

Represents the connector type for the line.

getConnectorType(): ConnectorType;

Returns

getEndArrowheadLength()

Represents the length of the arrowhead at the end of the specified line.

getEndArrowheadLength(): ArrowheadLength;

Returns

getEndArrowheadStyle()

Represents the style of the arrowhead at the end of the specified line.

getEndArrowheadStyle(): ArrowheadStyle;

Returns

getEndArrowheadWidth()

Represents the width of the arrowhead at the end of the specified line.

getEndArrowheadWidth(): ArrowheadWidth;

Returns

getEndConnectedShape()

Represents the shape to which the end of the specified line is attached.

getEndConnectedShape(): Shape;

Returns

getEndConnectedSite()

Represents the connection site to which the end of a connector is connected. Returns null when the end of the line is not attached to any shape.

getEndConnectedSite(): number;

Returns

number

getId()

Specifies the shape identifier.

getId(): string;

Returns

string

getIsBeginConnected()

Specifies if the beginning of the specified line is connected to a shape.

getIsBeginConnected(): boolean;

Returns

boolean

getIsEndConnected()

Specifies if the end of the specified line is connected to a shape.

getIsEndConnected(): boolean;

Returns

boolean

getShape()

Returns the Shape object associated with the line.

getShape(): Shape;

Returns

setBeginArrowheadLength(beginArrowheadLength)

Represents the length of the arrowhead at the beginning of the specified line.

setBeginArrowheadLength(beginArrowheadLength: ArrowheadLength): void;

Parameters

beginArrowheadLength
ExcelScript.ArrowheadLength

Returns

void

setBeginArrowheadStyle(beginArrowheadStyle)

Represents the style of the arrowhead at the beginning of the specified line.

setBeginArrowheadStyle(beginArrowheadStyle: ArrowheadStyle): void;

Parameters

beginArrowheadStyle
ExcelScript.ArrowheadStyle

Returns

void

setBeginArrowheadWidth(beginArrowheadWidth)

Represents the width of the arrowhead at the beginning of the specified line.

setBeginArrowheadWidth(beginArrowheadWidth: ArrowheadWidth): void;

Parameters

beginArrowheadWidth
ExcelScript.ArrowheadWidth

Returns

void

setConnectorType(connectorType)

Represents the connector type for the line.

setConnectorType(connectorType: ConnectorType): void;

Parameters

Returns

void

setEndArrowheadLength(endArrowheadLength)

Represents the length of the arrowhead at the end of the specified line.

setEndArrowheadLength(endArrowheadLength: ArrowheadLength): void;

Parameters

endArrowheadLength
ExcelScript.ArrowheadLength

Returns

void

setEndArrowheadStyle(endArrowheadStyle)

Represents the style of the arrowhead at the end of the specified line.

setEndArrowheadStyle(endArrowheadStyle: ArrowheadStyle): void;

Parameters

endArrowheadStyle
ExcelScript.ArrowheadStyle

Returns

void

setEndArrowheadWidth(endArrowheadWidth)

Represents the width of the arrowhead at the end of the specified line.

setEndArrowheadWidth(endArrowheadWidth: ArrowheadWidth): void;

Parameters

endArrowheadWidth
ExcelScript.ArrowheadWidth

Returns

void