Knowledgebase:
GetChartHistory
Posted by Mohammad Rahhal, Last modified by Rawan Al Hourani on 31 July 2016 11:07 AM

Syntax

 Public Function GetChartHistory(SymbolID As Integer, Period As PeriodNoEnum, BeforeDate As Date, NumberOfBars As Integer) As CallingResultsEnum

This method is used to return the open, close, high and low prices for the chart on specific period. After GetChartHistory method executes the ChartHistoryRecieved event fires.

Parameters

Parameter Description 
SymbolID Trading symbol name to get its' history , value of type Integer
Period Chart time frame, value of type PeriodNoEnum
BeforeDate Date value to get the previous chart history
NumberOfBars Bars Count to get its' history , value fo type Integer

Return value

Return value of type CallingResultsEnum,if the request sent to the server successfully it will return SuccessResult. 

Sample

 Private Sub Button1_Click (ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click 

   'API is a predefined variable as CVertexFXClientAPI10

    Dim Result As CVertexFXClientAPI10.CallingResultsEnum

    Result = API.GetChartHistory(API.SymbolByName("GOLD").ID, OneMinute, Now, 5000)

    Msgbox ("Get Chart history result: " & Result.ToString)

 End Sub


See Also


VertexFX Client API Index

(2 vote(s))
Helpful
Not helpful

Comments (0)
Post a new comment
 
 
Full Name:
Email:
Comments:
CAPTCHA Verification 
 
Please enter the text you see in the image into the textbox below (we use this to prevent automated submissions).

Help Desk Software by Hybrid Solutions