TPenStyle

An enumeration that defines the style of lines used in indicators and chart objects.

Values

Value
Description

SOLID

A solid line

DASH

A dashed line (- - -)

DOT

A dotted line (. . .)

DASHDOT

A line with alternating dashes and dots (- . - .)

DASHDOTDOT

A line with dashes and double dots (- . . - . .)

Example Usage

// Create a solid line level
this.api.AddLevel(70, TPenStyle.SOLID, 1, "#FF0000", 1);

// Create a dashed line level
this.api.AddLevel(30, TPenStyle.DASH, 1, "#00FF00", 1);

// Create a dotted middle line
this.api.AddLevel(50, TPenStyle.DOT, 1, "#808080", 0.7);

Last updated