Hide all indicator data after a certain date
to get line time use ObjectGetInteger(0,"line_name",OBJPROP_TIME,0)
if you need to monitoring line position, use OnChartEvent Function.
if you go by second way and make indicator mask, use iCustom function.
First way much easier, but its required original source of indicator (mq4 or mq5 file).
Indicators have main function OnCalculate and construction inside like this:
for(i=0; i<limit; i++) or for(int i=start; i<rates_total && !IsStopped(); i++)
this is cycle for calculate each bar value of the line.
modify it by replacing border values for bar index with line.
To get bar index by time easily, use iBarShift function.
Please consider which section is most appropriate — https://www.mql5.com/en/forum/172166/page6#comment_49114893
I would like to hide all indicators data on the chart after the date of a vertical line drawn (named "RANGE_END"). For example in the following diagrams, left chart is before the vertical line is drawn, right chart is when the vertical line is added, I would like to hide all the data after the line (the zigzag is my own EA, I have written logic to hide, but I want to know how to hide the multiple moving averages indicator).