I opened a chart of GOOG,D and it displayed a chart of 304 bars.
I added the following script to the chart:
"use strict;"
var barCount = 0;
var aGE = null;
function main() {
++barCount;
if (isLastBarOnChart() == true) {
aGE = sym("GE");
debugPrintln("barCount="+barCount);
debugPrintln(JSON.stringify(['isLastBarOnChart,high(0,aGE)', high(0,aGE)]));
}
return;
}
And the following is displayed in the output window:
["isLastBarOnChart,high(0,aGE)",31.28]
barCount=304
["isLastBarOnChart,high(0,aGE)",null]
barCount=304
It appears isLastBarOnChart() is true twice, i.e. the chart, or something, is loaded twice. Any thoughts on why this happens and what the multiple loads mean? I'm sure I just don't quite understand what's called and when.
Thanks
I added the following script to the chart:
"use strict;"
var barCount = 0;
var aGE = null;
function main() {
++barCount;
if (isLastBarOnChart() == true) {
aGE = sym("GE");
debugPrintln("barCount="+barCount);
debugPrintln(JSON.stringify(['isLastBarOnChart,high(0,aGE)', high(0,aGE)]));
}
return;
}
And the following is displayed in the output window:
["isLastBarOnChart,high(0,aGE)",31.28]
barCount=304
["isLastBarOnChart,high(0,aGE)",null]
barCount=304
It appears isLastBarOnChart() is true twice, i.e. the chart, or something, is loaded twice. Any thoughts on why this happens and what the multiple loads mean? I'm sure I just don't quite understand what's called and when.
Thanks
Comment