GetTimeByIndex - method of the tvPoints object
Description:
Returns the time of the nIndex-th data point. Specified value of the index depends on the nIndexType parameter and refers either to the whole buffer or only to the visible part of the buffer.
Syntax:
Date GetTimeByIndex(Long nIndex, Long nIndexType)
Parameters:
nIndex | (Long) Index to the buffer array
>=0 - Index to the buffer array
-2 - The time of the latest data point is returned |
nIndexType | (Long) Required type of the returned index
0 - Index refers to the beginning of the buffer
1 - Index refers to the first data point that is displayed by the buffer viewer |
---|
Return value:
The method returns the time.
If no point has been found then the method returns:
null for
JavaScript or
Empty for
VBScript (it can be tested by the
Pm.IsValid method).