I have an indicator which calculates the entry and stop and draws this information in the chart.
Now I would like to create a strategy with this indicator. However I do not want to copy the entry/stop code from the indicator to the strategy.
My idea was to add a public List to the indicator which contains all entry and stop information. Items are added to the list in the Indicator.OnBarUpdate().
However if I try to access the list in Strategy.OnBarUpdate() the list is always empty because the indicator is calculated *after* the strategy. That doesnt make sense to me. My expectation would be that all indicators are already calculated to the current bar of Strategy.OnBarUpdate.
Would you please help me with this?
Thanks a lot and greetings,
Bobin
Comment