I'm trying to modify manually drawn rectangles from within a strategy and found unexpected behaviour when I scan DrawObjects looking for rectangles. Perhaps I am missing something, but it seems strange to me.
This condition does not always return true for rectangles.
drawObj is DrawingTools.Rectangle
Compile the strategy.
Attach it to a chart.
Draw a rectangle.
Enable the strategy for a few ticks.
The output should show the condition true. (Correct)
Compile the strategy again (without change).
Enable the strategy again for a few ticks.
Now the output shows the condition false, i.e. the rectangle is not a rectangle.
Add another rectangle.
Enable the strategy for a few ticks.
Now the rectangle(s) drawn before the last compile show false, but rectangles drawn since show true.
Cheers
Tony
Comment