Knowledgebase : Technical Support > API > Client API's/VTL > VTL Client Scripts > Chart Operation
Syntax  Public Function GetChartIDByIndex(Index As Integer) As Long DESCRIPTION This function is used to get the chart identifier to the given chart index. PARAMETERS Key Description  Index The chart position on the chart windows, value ...
Syntax  Public Function GetChartPeriod(chartIndex As Integer) As Integer DESCRIPTION This function is used to get the active period for the given chart index. PARAMETERS Key Description  chartIndex The chart position on the chart windows...
Syntax  Public Function GetChartSymbol(chartIndex As Integer) As String DESCRIPTION This function is used to get the symbol name for the given chart index. PARAMETERS Key Description  chartIndex The chart position on the chart windows.0 ...
Syntax Public Function ChartsTotal() As Integer DESCRIPTION This function is used to get the count of the opened chart. PARAMETERS No parameters RETURN VALUE Returns the total number of the opened chart as a value of type integer. SAMPLE    Publ...
Syntax  Public Function ActivateChartByID(ChartId As Long) As Boolean This function is used to make the given chart identifier is the active chart. PARAMETERS Key Description  Index The chart position on the chart windows to be active. A ...
Syntax  Public Function ActivateChartByIndex(Index As Integer) As Boolean DESCRIPTION This function is used to make the given chart index is the active chart. PARAMETERS Key Description  Index The chart position on the chart windows to b...
Syntax  Public Function VisibleBarsCount (chartIndex As Integer) As Long DESCRIPTION This Function is used to return the count of the visible bars on the specific chart. PARAMETERS Key Description  Chart_index          The chart position...
Syntax  Public Function SubWindowsTotal (chart_index As Integer) As Long DESCRIPTION This function is used to return the number of opened sub-windows on the specific chart. PARAMETERS Key Description  Chart_index          The chart posit...
Syntax  Public Function GetPanelPriceMin (chartIndex As Integer, Panel As Long) As Double DESCRIPTION This function is used to return the minimum value of the vertical scale of the specified sub-window of the given chart index. PARAMETERS Key D...
Syntax  Public Function GetPanelPriceMax (chartIndex As Integer, Panel As Long) As Double DESCRIPTION This function is used to return the maximum value of the vertical scale of the specified sub-window in the given chart index. PARAMETERS Key D...
Syntax  Public Function LastVisibleBar (chartIndex As Integer) As Long  DESCRIPTION This function is used to return the index of the last visible bar in the chart. PARAMETERS Key Description  chartIndex The chart position on the chart wind...
Syntax  Public Function FirstVisibleBar (chartIndex As Integer) As Long DESCRIPTION This function is used to get an index of the first visible bar in the chart. PARAMETERS Key Description  chartIndex The chart position on the chart windows...
Syntax  Public Function windowHandle (Symbol As String, timeFrame As ENUM_TIMEFRAMES) As Integer DESCRIPTION This function is used to return the chart index depending on the chart symbol name and time frame. PARAMETERS Key Description  Symb...
Syntax  Public Function ChartHigh () As Integer DESCRIPTION This function is used to return a high value of the chart. Parameters No Parameters RETURN VALUE Returns the high value on the chart as type Integer. SAMPLE  Public Sub main()     Alert...
Syntax  Public Function ChartWidth ()  As Integer DESCRIPTION This Function is used to return the width of the chart value. PARAMETERS No Parameters RETURN VALUE Returns the chart width value as type Integer. SAMPLE  Public Sub main()     AlertM...
Syntax Public Function ChartSymbolId(Optional chart_ID As Integer=0) As Integer DESCRIPTION This function is used to return the symbol ID for the given chart identifier. PARAMETERS Key Description  Chart_ID Chart identifier to know it sy...
Syntax  Public Function GetChartData(Chart_ID As Integer, RowsCount As Long) As Boolean DESCRIPTION This function is used to load specific bars number on a given chart. PARAMETERS Key Description  Chart_ID ID of chart to be loaded , 0 me...
SYNTAX Public Function GetSubWindow(chart_Id As Long, seriesName As String) As Long DESCRIPTION This function is used to get the index of the window (panel) where the object was added. The returned index must exceed or equal 0. PARAMETERS Key D...
SYNTAX Public Function SetChartScale(chart_id As Long,win As Long, maxVal As Double, minVal As Double) As Boolean DESCRIPTION This function is used to change where the scale begins and ends based on the max and min values. The max value must be greater...
SYNTAX Public Function ChartNavigate(chart_id As Long, Position As ENUM_CHART_POSITION, Optional Shift As Variant = 0) As Boolean DESCRIPTION This function is used to shift the specified chart by the specified number of bars in the chart. PARAMETERS ...
SYNTAX Public Function ChartScreenShot(chart_id As Long, FileName As String) As Boolean DESCRIPTION This function is used to take a snapshot of the specified chart with a specific name.  PARAMETERS Key Description  chart_id Chart ID. 0 i...
SYNTAX  Public Function ChartSetSymbolPeriod(chart_id As Long, Period As ENUM_TIMEFRAMES)As Boolean This function is used to change the period of the specified given the chart with a new time frame. PARAMETERS Key Description chart_id Cha...
SYNTAX  Public Function ChartFirst() As Long DESCRIPTION This function is used to return the ID of the first chart in chart windows. PARAMETERS No parameters. RETURN VALUE Returns the chart ID as a value of type is long .Returns -1 if an error occu...
SYNTAX  Public Sub ChartRedraw(Optional chart_id As Long = 0) DESCRIPTION This function is used to redraw the specified chart after changing it. PARAMETERS Key Description chart_id Chart ID, 0 is the current chart, value of type Long. R...
SYNTAX  Public Function chartID() As Long DESCRIPTION This function is used to return the ID of the current chart. PARAMETERS No parameters. RETURN VALUE Returns chart ID as a value of type long. SAMPLE Public Sub main() AlertMessage ChartID() '...
SYNTAX  Public Function ChartPeriod(Optional chart_id As long = 0) As Integer DESCRIPTION This function is used to return the timeframe value (one of the ENUM_TIMEFRAMES [http://www.hybrid-solutions.com/support/index.php?/Knowledgebase/Article/View/192...
SYNTAX  Public Function ChartSymbol(Optional chart_id As Long = 0) As String DESCRIPTION This function is used to return the symbol name for the specified chart by a given the chart ID. PARAMETERS Key Description chart_id Chart identifie...
SYNTAX Public Function ChartClose(Optional chart_id As Long = 0) As Boolean DESCRIPTION This function is used to close the specified chart by a given the chart ID. PARAMETERS Key Description  chart_id Chart ID, 0 is the current chart, va...
SYNTAX  Public Function ChartNext(chart_id As Variant)As Long DESCRIPTION This function used to return the chart ID of the  next chart by given the wanted chart ID. PARAMETERS Key Description chart_id Chart identifier that want to know t...
SYNTAX Public Function ChartOpen(Symbol As String, Period As ENUM_TIMEFRAMES) As Integer DESCRIPTION This function is used to open a new chart with the specified symbol and specified period. PARAMETERS Key Description Symbol Symbol name ...
Help Desk Software by Hybrid Solutions