@l-andorrà
https://fxdreema.com/shared/n13e1VVhb

This screen is from a backtest, but when placed on the live account, the sum is not being done.
@l-andorrà
https://fxdreema.com/shared/n13e1VVhb

This screen is from a backtest, but when placed on the live account, the sum is not being done.
Is there any way to slide the order along with a moving average?
Friends, I believe it is a "bug" but posted here to try to get help from you.
The " Bucket of positions " block works perfectly in the backtest, but it doesn't work in the real market.
I just want to get the amount of open positions in real time without having to do a manual count using variables.
The importance of using this block in this way is that if the EA is removed from the screen, when it returns to the screen it will perform a new count.
Unfortunately on the real account he is not counting.

@l-andorrà
I do, well, at least for the backtest it's working, I'm going to test it in the real market to validate it.
what is your opinion about this solution?
https://fxdreema.com/shared/m47kjm9uc
Try to take advantage of something in this project of mine to see if it helps you with your goal.
If there were any doubts let me know.
@piptheripper great my friend, thanks i will wait this solution by @fxdreema
@ontradingx 
Try to use this.
" Block Close Profitable Position"
It's been working for me.
@piptheripper
https://fxdreema.com/forum/topic/13977/closing-an-order-always-with-a-positive-value/10
Hello friend, this is something old, I've been trying to get clear answers about it but I can't, I saw that there are other similar posts, I'm starting to believe that there isn't a solution and that the block isn't doing the correct calculation.
@fxdreema
Could you help us to solve this problem?
To understand what I'm saying, create a basic EA with multiple pairs and order it to end trading only at profit, neither can be a loss.
@l-andorrà can you give me an example?
I didn't understand what you meant
@l-andorrà @biztet
I'm testing a second option that would be as follows:
I monitor the gain for when it hits $3 then the trailling stop guarantees me $2.50 and walks every step.
I don't know if I'm doing the right thing, but at least I realized that this allowed me to no longer have negative closed orders.
I will test other methods.

@l-andorrà I also agree that the first option is ideal, but the (correct) is the tool to calculate alone regardless of the broker dictating the rules, we already know that most brokers are fraudulent about not benefiting us, so the EA has to strictly follow the rule imposed on him.
@biztet I have tried from other brokers and the same problem persists, but I believe that maybe this is an Fxdreema problem that should be solved, the correct thing is to automatically calculate all the fees.
For those who want to work without stop loss, this is a huge risk as the intention is never to close any negative order.
@ontradingx
I already tried with these 3 conditions.
https://fxdreema.com/shared/HntxOBXRc
But for some reason I realize that maybe Swap or commissions are not being calculated and some order ends up ending up in the total sum negatively.
I just want my EA to check every order, regardless of which pair is open, when the order total sum including Swap, commissions or any other fee, when it reaches a positive $3 will close the order immediately.
That is, the EA cannot admit that any order is negatively closed.
Hello all,
I'm trying to always close orders with positive values but for some reason I don't know the EA is not adding up fees and commissions and closes orders with negative values.
Does anyone have any tips on how to order the EA to close any order whenever the sum total value is positive?
I have already tested the For each position block with the rule in the condition for Profit+swap and commissions.
I have already tested the bucket of positions with sum profit.
None of this is working properly.
@slimmz this duck noise you mention could be happening maybe due to your metatrader's history issues.
Are you Brazilian?
If so, I can give you my contact in private to help you with some things I know about.
@slimmz this is a backtest result with the indicator I sent you, but I have all the financial management that I put in my robots.
Order Quantity Limiter
earnings limiter
loss limiter
goals
I suggest you migrate to Metatrader 5, I think it's the easiest to work with backtests.
@slimmz 
This technique is very good, I'm working on it for a very fast market and short targets, the hard part is that everything has to be tested in a real market.
This backtest result doesn't mean anything yet.
@slimmz Your strategy is easy to do, but to do it correctly you need to get a correct indicator and understand how it actually works.
This indicator that I posted just now I believe is the most correct to execute what you or I need, my strategy is very similar to yours, but I am prevented from doing it due to lack of knowledge of mql5 and adjust this indicator to work on Fxdreema perfectly, sorry.