Hello Scriptor, Although you published TMA_Extreme_line_indicator some time ago, I have just discovered it... And I love it !!! I am trying to use it to automate some operations, using iCustom to fill an array and get the values of the middle line into some variables. However, I am not able to get the values of the middle line in mode "redraw INPUT_YES". I can only get the values of the "redraw INPUT_NO", even when I represent the indicator in INPUT_YES. This is the code I am using:
Would you be so kind to let me know if I am missing something in the code to be able to get to fill the variables TMA_1, TMA_2 & TMA_3 with the "redraw INPUT_YES" values? Or , Would it be possible to get the indicator re-written so that these values become accessible? Many thanks.
Would you be so kind to let me know if I am missing something in the code to be able to get to fill the variables TMA_1, TMA_2 & TMA_3 with the "redraw INPUT_YES" values? Or , Would it be possible to get the indicator re-written so that these values become accessible? Many thanks.
Would it be possible to have a colouring rule for the candles based on the indicator so that when it leaves the bands it starts colouring them for buy or sell?
I am new to MT platforms... Thank you! Is there a way to incorporate color change alerts into the code? I will learn how, please direct me! Thank you for coding this one. :-)
When using this indicator with Redraw set to YES, its draws the lines beatifully. But I'm writing an EA and CopyBuffer() always returns the values as if it is set to Redraw NO.
I have been looking at this beautiful channel indicator for a long time. It was amazing how it detects the channel. I looked at the code - oops. The indicator counts only on historical data, but if there is a possibility, it looks forward to the size of the TMA. Wow, what a move :)))
Although you published TMA_Extreme_line_indicator some time ago, I have just discovered it... And I love it !!!
I am trying to use it to automate some operations, using iCustom to fill an array and get the values of the middle line into some variables.
However, I am not able to get the values of the middle line in mode "redraw INPUT_YES". I can only get the values of the "redraw INPUT_NO", even when I represent the indicator in INPUT_YES.
This is the code I am using:
enum ENUM_INPUT_YES_NO
{
INPUT_YES = 1, // Yes
INPUT_NO = 0 // No
};
input TMAPeriods = 20
input TMA_ATRPeriods = 20
input TMA_ATRWidth = 3
input ENUM_INPUT_YES_NO InpRedraw = INPUT_YES; // Redraw
double TMA[];
int TMAControlPanel;
double TMA_1, TMA_2, TMA_3;
int OnInit()
{
ArraySetAsSeries(SlowTMADATA,true);
TMAControlPanel = iCustom(_Symbol, PERIOD_CURRENT, "TMA_Extreme_line_indicator", TMAPeriods, TMA_ATRPeriods, TMA_ATRWidth, INPUT_YES);
}
void OnDeinit(const int reason)
{
IndicatorRelease(TMAControlPanel);
}
void OnTick()
{
CopyBuffer(TMAControlPanel, 0, 0, 5, TMADATA);
TMA_1 = NormalizeDouble(TMADATA[1],6);
TMA_2 = NormalizeDouble(TMADATA[2],6);
TMA_3 = NormalizeDouble(TMADATA[3],6);
}
Would you be so kind to let me know if I am missing something in the code to be able to get to fill the variables TMA_1, TMA_2 & TMA_3 with the "redraw INPUT_YES" values?
Or , Would it be possible to get the indicator re-written so that these values become accessible?
Many thanks.
}
void OnTick()
{
CopyBuffer(TMAControlPanel, 0, 0, 5, TMADATA);
TMA_1 = NormalizeDouble(TMADATA[1],6);
TMA_2 = NormalizeDouble(TMADATA[2],6);
TMA_3 = NormalizeDouble(TMADATA[3],6);
}
Would you be so kind to let me know if I am missing something in the code to be able to get to fill the variables TMA_1, TMA_2 & TMA_3 with the "redraw INPUT_YES" values?
Or , Would it be possible to get the indicator re-written so that these values become accessible?
Many thanks.
When using this indicator with Redraw set to YES, its draws the lines beatifully. But I'm writing an EA and CopyBuffer() always returns the values as if it is set to Redraw NO.
Has anyone else had this problem.?
Cheers Pete
INPUT_YES = 1, // Yes
INPUT_NO = 0 // No
I have been looking at this beautiful channel indicator for a long time. It was amazing how it detects the channel. I looked at the code - oops. The indicator counts only on historical data, but if there is a possibility, it looks forward to the size of the TMA. Wow, what a move :)))