Login Page - Create Account

Support Board


Date/Time: Thu, 27 Feb 2025 12:51:45 +0000



Post From: Force recalculation of a study when user drawn drawing is moved

[2021-06-28 16:23:37]
ATricky1 - Posts: 16
I've been struggling to find out how to do this in ACSIL. I've trawled the documentation but can't find a solution - but maybe I've missed something.

I've coded a study to start a plot based on an anchor (vertical line user drawn drawing) as a start point. The study creates the line and the plot is created from that bar onwards. However, on moving the line the plot is not re-adjusted.

1) Autoloop is set to 1
2) Chart interval update is set to 500 msecs
3) I'm running this out of market hours which I guess may affect any update?
4) sc.RecalculateChartImmediate(0) won't work - presumably because the code isn't being rerun anyway.
4) On turning Trade Simulation on or off it will update the study / plot as will adding any other study or 'Apply'. The documentation infers this anyway.

If the line is moved manually then I need the study to be run - the plot re-adjusted without me having to hit any buttons or select any other options.

Can the line be polled for any movement from the existing study or any other study/option? I need this outside of the symbol market hours when no ticks are coming in.

Thanks.