TrnGetSpan
Gets the span time of a trend (if the span was set by the TrnSetSpan() function). The span time is the total time displayed in the trend window.
Note: If you call the TrnSetPeriod() function after the TrnSetSpan() function, the span is automatically set to 0 (zero).
Syntax
TrnGetSpan(AN)
AN:
The AN of the chosen trend.
Return Value
The span time, in seconds. 0(zero) is returned if the AN is invalid or if the span was not set by the TrnSetSpan() function.
Related Functions
TrnSetSpan, TrnGetPeriod, TrnSetPeriod
Example
// Use a keyboard command or button to set a span of 2 hours.
TrnSetSpan(40,StrToTime("2:00:00");
// Then use TrnGetSpan function to display the span
Time = TrnGetSpan(40)
DspText(31,0,TimeToStr(Time,5));
See Also