With reference to the code below,
I want to inform you that I tried everything, read every treat, downloaded every solution to create my request without issues, without a hope I decided to right you in the forum.
My request is simple when 3 steps in order are fulfilled, and a final entry steps shows I want to plot an arrow. At the final step which will be my entry point manually.
Somehow, the indicator do not define the bool.
To find my mistake I plotted an arrow at the end of each step to understand the issue. So the code run without a bug, however, it plots regarding the situation without considering the bool I created, did I missed something?
Please, can you help me.
[COLOR=blue][FONT="]public[/FONT][/COLOR][COLOR=blue][FONT="]class[/FONT][/COLOR][COLOR=black][FONT="] bool_V10 : Indicator[/FONT][/COLOR] [COLOR=black][FONT="] {[/FONT][/COLOR] [COLOR=blue][FONT="]#region[/FONT][/COLOR][COLOR=black][FONT="] Variables[/FONT][/COLOR] [COLOR=green][FONT="]// Wizard generated variables[/FONT][/COLOR] [COLOR=blue][FONT="]private[/FONT][/COLOR][COLOR=blue][FONT="]bool[/FONT][/COLOR][COLOR=black][FONT="] condition1 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="]; [/FONT][/COLOR][COLOR=green][FONT="]// Default setting for Condition1[/FONT][/COLOR] [COLOR=blue][FONT="]private[/FONT][/COLOR][COLOR=blue][FONT="]bool[/FONT][/COLOR][COLOR=black][FONT="] condition2 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="]; [/FONT][/COLOR][COLOR=green][FONT="]// Default setting for Condition2[/FONT][/COLOR] [COLOR=blue][FONT="]private[/FONT][/COLOR][COLOR=blue][FONT="]bool[/FONT][/COLOR][COLOR=black][FONT="] condition3 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="]; [/FONT][/COLOR][COLOR=green][FONT="]// Default setting for Condition3[/FONT][/COLOR] [COLOR=green][FONT="]// User defined variables (add any user defined variables below)[/FONT][/COLOR] [COLOR=blue][FONT="]#endregion[/FONT][/COLOR] [COLOR=gray][FONT="]///[/FONT][/COLOR][COLOR=gray][FONT="]<summary>[/FONT][/COLOR] [COLOR=gray][FONT="]///[/FONT][/COLOR][COLOR=green][FONT="] This method is used to configure the indicator and is called once before any bar data is loaded.[/FONT][/COLOR] [COLOR=gray][FONT="]///[/FONT][/COLOR][COLOR=gray][FONT="]</summary>[/FONT][/COLOR] [COLOR=blue][FONT="]protected[/FONT][/COLOR][COLOR=blue][FONT="]override[/FONT][/COLOR][COLOR=blue][FONT="]void[/FONT][/COLOR][COLOR=black][FONT="] Initialize()[/FONT][/COLOR] [COLOR=black][FONT="] {[/FONT][/COLOR] [COLOR=black][FONT="] Add([/FONT][/COLOR][COLOR=blue][FONT="]new[/FONT][/COLOR][COLOR=black][FONT="] Plot([/FONT][/COLOR][COLOR=blue][FONT="]new[/FONT][/COLOR][COLOR=black][FONT="] Pen(Color.SpringGreen,[/FONT][/COLOR][COLOR=purple][FONT="]5[/FONT][/COLOR][COLOR=black][FONT="]), PlotStyle.TriangleUp, [/FONT][/COLOR][COLOR=maroon][FONT="]"Plot1"[/FONT][/COLOR][COLOR=black][FONT="]));[/FONT][/COLOR] [COLOR=black][FONT="] Add([/FONT][/COLOR][COLOR=blue][FONT="]new[/FONT][/COLOR][COLOR=black][FONT="] Plot([/FONT][/COLOR][COLOR=blue][FONT="]new[/FONT][/COLOR][COLOR=black][FONT="] Pen(Color.Crimson,[/FONT][/COLOR][COLOR=purple][FONT="]5[/FONT][/COLOR][COLOR=black][FONT="]), PlotStyle.TriangleDown, [/FONT][/COLOR][COLOR=maroon][FONT="]"Plot2"[/FONT][/COLOR][COLOR=black][FONT="]));[/FONT][/COLOR] [COLOR=black][FONT="] Add([/FONT][/COLOR][COLOR=blue][FONT="]new[/FONT][/COLOR][COLOR=black][FONT="] Plot([/FONT][/COLOR][COLOR=blue][FONT="]new[/FONT][/COLOR][COLOR=black][FONT="] Pen(Color.DodgerBlue,[/FONT][/COLOR][COLOR=purple][FONT="]5[/FONT][/COLOR][COLOR=black][FONT="]), PlotStyle.TriangleUp, [/FONT][/COLOR][COLOR=maroon][FONT="]"Plot3"[/FONT][/COLOR][COLOR=black][FONT="]));[/FONT][/COLOR] [COLOR=black][FONT="] Add([/FONT][/COLOR][COLOR=blue][FONT="]new[/FONT][/COLOR][COLOR=black][FONT="] Plot([/FONT][/COLOR][COLOR=blue][FONT="]new[/FONT][/COLOR][COLOR=black][FONT="] Pen(Color.Yellow,[/FONT][/COLOR][COLOR=purple][FONT="]5[/FONT][/COLOR][COLOR=black][FONT="]), PlotStyle.TriangleDown, [/FONT][/COLOR][COLOR=maroon][FONT="]"Plot4"[/FONT][/COLOR][COLOR=black][FONT="]));[/FONT][/COLOR] [COLOR=black][FONT="] Overlay = [/FONT][/COLOR][COLOR=blue][FONT="]true[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=black][FONT="] }[/FONT][/COLOR] [COLOR=gray][FONT="]///[/FONT][/COLOR][COLOR=gray][FONT="]<summary>[/FONT][/COLOR] [COLOR=gray][FONT="]///[/FONT][/COLOR][COLOR=green][FONT="] Called on each bar update event (incoming tick)[/FONT][/COLOR] [COLOR=gray][FONT="]///[/FONT][/COLOR][COLOR=gray][FONT="]</summary>[/FONT][/COLOR] [COLOR=blue][FONT="]protected[/FONT][/COLOR][COLOR=blue][FONT="]override[/FONT][/COLOR][COLOR=blue][FONT="]void[/FONT][/COLOR][COLOR=black][FONT="] OnBarUpdate()[/FONT][/COLOR] [COLOR=black][FONT="] {[/FONT][/COLOR] [COLOR=blue][FONT="]if[/FONT][/COLOR][COLOR=black][FONT="] (Step A == True)[/FONT][/COLOR] [COLOR=black][FONT="] Plot3.Set(Low[[/FONT][/COLOR][COLOR=purple][FONT="]0[/FONT][/COLOR][COLOR=black][FONT="]] - ([/FONT][/COLOR][COLOR=purple][FONT="]3[/FONT][/COLOR][COLOR=black][FONT="] * TickSize)); [/FONT][/COLOR] [COLOR=black][FONT="] condition1 = [/FONT][/COLOR][COLOR=blue][FONT="]true[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=black][FONT="] condition2 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=black][FONT="] condition3 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=blue][FONT="]if[/FONT][/COLOR][COLOR=black][FONT="] ( Step B == [/FONT][/COLOR][COLOR=blue][FONT="]true[/FONT][/COLOR] [COLOR=black][FONT="] && condition1 == [/FONT][/COLOR][COLOR=blue][FONT="]true[/FONT][/COLOR] [COLOR=black][FONT="] && condition2 != [/FONT][/COLOR][COLOR=blue][FONT="]true[/FONT][/COLOR] [COLOR=black][FONT="] && condition3 != [/FONT][/COLOR][COLOR=blue][FONT="]true[/FONT][/COLOR][COLOR=black][FONT="])[/FONT][/COLOR] [COLOR=black][FONT="] Plot4.Set(High[[/FONT][/COLOR][COLOR=purple][FONT="]0[/FONT][/COLOR][COLOR=black][FONT="]] + ([/FONT][/COLOR][COLOR=purple][FONT="]3[/FONT][/COLOR][COLOR=black][FONT="] * TickSize)); [/FONT][/COLOR] [COLOR=black][FONT="] condition1 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=black][FONT="] condition2 = [/FONT][/COLOR][COLOR=blue][FONT="]true[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=black][FONT="] condition3 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=blue][FONT="]if[/FONT][/COLOR][COLOR=black][FONT="] (Step C == true[/FONT][/COLOR] [COLOR=black][FONT="]&& condition1 != [/FONT][/COLOR][COLOR=blue][FONT="]true[/FONT][/COLOR] [COLOR=black][FONT="] && condition2 == [/FONT][/COLOR][COLOR=blue][FONT="]true[/FONT][/COLOR] [COLOR=black][FONT="] && condition3 != [/FONT][/COLOR][COLOR=blue][FONT="]true)[/FONT][/COLOR] [COLOR=black][FONT="] Plot1.Set(Low[[/FONT][/COLOR][COLOR=purple][FONT="]0[/FONT][/COLOR][COLOR=black][FONT="]] - ([/FONT][/COLOR][COLOR=purple][FONT="]3[/FONT][/COLOR][COLOR=black][FONT="] * TickSize)); [/FONT][/COLOR] [COLOR=black][FONT="] condition1 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=black][FONT="] condition2 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=black][FONT="] condition3 = [/FONT][/COLOR][COLOR=blue][FONT="]true[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=blue][FONT="]if[/FONT][/COLOR][COLOR=black][FONT="] (Final Step == True[/FONT][/COLOR] [COLOR=black][FONT="]&&condition1 == [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR] [COLOR=black][FONT="] && condition2 == [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR] [COLOR=black][FONT="] && condition3 == [/FONT][/COLOR][COLOR=blue][FONT="]true)[/FONT][/COLOR] [COLOR=black][FONT="] Plot2.Set(High[[/FONT][/COLOR][COLOR=purple][FONT="]0[/FONT][/COLOR][COLOR=black][FONT="]] + ([/FONT][/COLOR][COLOR=purple][FONT="]3[/FONT][/COLOR][COLOR=black][FONT="] * TickSize)); [/FONT][/COLOR] [COLOR=black][FONT="] condition1 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=black][FONT="] condition2 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=black][FONT="] condition3 = [/FONT][/COLOR][COLOR=blue][FONT="]false[/FONT][/COLOR][COLOR=black][FONT="];[/FONT][/COLOR] [COLOR=black][FONT="] }[/FONT][/COLOR]
Comment