Thanks Roar,
Your workaround it's certainly less complicated but is not what i want, because you are counting each bar waiting for the condition to buy, while i want a "picture" of X past bars at every new bar.
Anyway you suggested me where to focus my attention, and i discovered that i was using the wrong counter block. Using Loop (Pass "n" times) it works!
That's the right version:
https://fxdreema.com/shared/z2aQGGpae