I am analysing a third part AFL codes to learn how the developers use some functions and how they work. It is quite useful for me. Studying PlotOHLC function, I am having a little problem and I don't find what I am doing wrong.
I have learned to use it with an array but I am having problems when using it with a static value. Let me show you three simple AFL codes to explain my doubt.
If I use an array to determine the bar colour (as below), it works fine...
UpBar = Ref(C,0) > Ref(O,0); ChartColor=IIf(UpBar,colorBlue,colorOrange); PlotOHLC( Open, High, Low, Close, "Price Chart", ChartColor, styleBar);
... but if I try it with static colour value (see two AFL codes below), it doesn't work (I mean, I am doing wrong).
ChartColor = colorBlue; PlotOHLC( Open, High, Low, Close, "Price chart", ChartColor, styleBar );
PlotOHLC( Open, High, Low, Close, "Price chart", colorBlue, styleBar );
In both cases, I see bar colours as default (green and red), not blue. I feel that I am being blinded and I must escape something very obvious ... but, I'm sorry, I do not see it. I don't know if it is about my AFL code or my chart settings. Some help will be appreciated.