BarsReturns the number of bars count in the history for a specified symbol and period. There are 2 variants of functions calls. Request all of the history bars
Request the history bars for the selected time interval
Parameters symbol_name [in] Symbol name. timeframe [in] Period. start_time [in] Bar time corresponding to the first element. stop_time [in] Bar time corresponding to the last element. Return Value If the start_time and stop_time parameters are defined, the function returns the number of bars in the specified time interval, otherwise it returns the total number of bars. Note If data for the timeseries with specified parameters are not formed in the terminal by the time of the Bars() function call, or data of the timeseries are not synchronized with a trade server by the moment of the function call, the function returns a zero value. See also Predefined variable Bars, iBars |