Can't get this code to run properly:
ExampleStateStrategy Snippet:
......
else if (State == State.Configure)
{
AddChartIndicator(ExampleStateIndicator());
}
}
protected override void OnBarUpdate()
{
double data = ExampleStateIndicator()[0];
Print("STRATEGY - " + State);
}
protected override void OnBarUpdate()
{
Value[0] = 0;
Print("INDICATOR - " + State);
}
Strategy 'ExampleStateStrategy': Error on calling 'OnBarUpdate' method on bar 0: Index was outside the bounds of the array.
if(State < State.Realtime) return;
Strategy 'ExampleStateStrategy': Error on calling 'OnBarUpdate' method on bar 6997: Index was outside the bounds of the array.
Do you have a working example of this scenario working correctly?

Comment