ChartVerticalLine
interface cAlgo.API
DesktopCLICloud
Represents the Vertical Line chart object. The line parallel to the Y-axis that can be set on a certain time value on the X-axis.
Environment behaviour
CLI — works differently. Created and kept with all its properties, but never drawn: the CLI displays no chart.
Cloud — works differently. Created and kept with all its properties, but never drawn: the cloud displays no chart.
Definition
public interface ChartVerticalLine
Namespace: cAlgo.API · Group: Drawings · Implements: ChartObject
Examples
using cAlgo.API;
namespace cAlgo
{
// This sample shows how to draw a vertical line on chart by using Chart.DrawVertical line method
public partial class ChartVerticalLineSample : Indicator
{
protected override void Initialize()
{
var verticalLine = Chart.DrawVerticalLine("vertical_line", Chart.LastVisibleBarIndex, Color.Red, 2, LineStyle.DotsRare);
verticalLine.IsInteractive = true;
}
public override void Calculate(int index)
{
}
}
}
import clr
clr.AddReference("cAlgo.API")
from cAlgo.API import *
class Test():
def initialize(self):
verticalLine = api.Chart.DrawVerticalLine("vertical_line", api.Chart.LastVisibleBarIndex, Color.Red, 2, LineStyle.DotsRare)
verticalLine.IsInteractive = True
{
"AccessRights": "None",
"TimeZone": "UTC",
"IsOverlay": true
}
Properties
| Name | Description |
|---|---|
ColorDesktopCLICloudColor | Gets or sets the line color. |
LineStyleDesktopCLICloudLineStyle | Gets or sets the line style. |
ThicknessDesktopCLICloudint | Gets or sets the line thickness. |
TimeDesktopCLICloudDateTime | Gets or sets the value on the Time line. |
Inherited members
From ChartObject: Name, Comment, ObjectType, IsInteractive, IsLocked, IsHidden, ZIndex, IsAlive