Reopening of negotiations are not working properly.
-
Hello,
I realized that if I create an EA to trade in Forex, and I have conditions where when each trade when closed, either by take profit or stop loss, or even closed manually, I placed a block to reopen a new trade.
it's very simple:
No position buy
Buy now
If there are no positions, buy now.If the market closes and he closes the open position, because the market is closed he will not open the order, so far so good, but when the market returns to work / open, the order would have to be opened, and it is not being open, either for purchases or sales.
Can you please analyze?In Backtest, it works.
In the demo market, it doesn't work. -
@fabiobioware No link is included.
-
@l-andorrà I believe that it is not necessary, 2 blocks in a demo account will be able to prove this, I am using the broker FBS and Active Trades for testing.
-
@fabiobioware message error is:
2021.01.21 19:04:29.747 OntradingX2021 (USDJPY,H1) Closing position/trade error: No connection with the trade server (10031). Retrying in 5 seconds..
2021.01.21 19:04:29.747 OntradingX2021 (USDJPY,H1) retry #4 of 10 -
please create a replica of the error and share for us to test. People will be more likely to help you if you give them the tools to help them help you.
-
@jsauter86 https://fxdreema.com/shared/5LH9F59Kd
I don't have to replicate the error at this point because it happens only when the market closes and reopens, the market will close today and reopen on Sunday.
If it happens in any pair I put the print here on the screen.
For now I can only share this link to demonstrate how my first entries are being made. No strategy at all because I don't look at anything to make the first entry just this. -
@fabiobioware My guess (and it's just a guess) is that you broker changes the spread dramatically from one session to the next one. If the is trying to close an open trade, that sperad filter can be the reason of the error. Obviously I have no idea about programming, but did you try you EA in a broker with no spread change between sessions?
-
Spreads are much larger during rollover, is it just that?
-
Hello my friends, I have not tried any broker without spread, but I will try this week.
I honestly don't believe it's just a spread.
The reason I don't believe it is because it is quite clear that the "no position" block that is at the top in "on tick" should do its function of "having no position" to pass on to the next block, check the spread and open the order, and it should be constantly repetitive until the spread is at the desired size opening the order.
It is as if the block "No position" did not do its function correctly, if I do not have the position, it should pass on to the next block, very simple but it did not.
Anyway, I will analyze this week and post more evidence if it happens and if necessary, call the broker to find out if the mistake is with them or not.