Gamestudio Links
Zorro Links
Newest Posts
Blobsculptor tools and objects download here
by NeoDumont. 03/28/24 03:01
Issue with Multi-Core WFO Training
by aliswee. 03/24/24 20:20
Why Zorro supports up to 72 cores?
by Edgar_Herrera. 03/23/24 21:41
Zorro Trader GPT
by TipmyPip. 03/06/24 09:27
VSCode instead of SED
by 3run. 03/01/24 19:06
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (AndrewAMD, Imhotep), 567 guests, and 4 spiders.
Key: Admin, Global Mod, Mod
Newest Members
sakolin, rajesh7827, juergen_wue, NITRO_FOREVER, jack0roses
19043 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Entry and Exit different LotAmount #474834
11/08/18 16:53
11/08/18 16:53
Joined: Feb 2018
Posts: 236
Italy
tradingest Offline OP
Member
tradingest  Offline OP
Member

Joined: Feb 2018
Posts: 236
Italy
Hi guys,

using the code below to exit from trade I seen that the exit trade is not completed. Does not match the entry LotAmount
Code:
for(open_trades)
{
exitTrade(ThisTrade);
}


I'm entry with 0.29 lots and I'm exit with only 0.01 using the code above. Why? I used the MT4 bridge with 1.96 Zorro version.

Thanks

Re: Entry and Exit different LotAmount [Re: tradingest] #474846
11/09/18 09:17
11/09/18 09:17
Joined: Jul 2000
Posts: 27,977
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,977
Frankfurt
There can be several reasons of not fully closing trades, like an NFA or FIFO issue or a closed market. You can normally see the reason in the MQ4 log. If not, please post the log.

Re: Entry and Exit different LotAmount [Re: jcl] #474860
11/09/18 18:23
11/09/18 18:23
Joined: Feb 2018
Posts: 236
Italy
tradingest Offline OP
Member
tradingest  Offline OP
Member

Joined: Feb 2018
Posts: 236
Italy
Hi jcl,

thanks for the support.
As you see Zorro close only 0.01 and not the whole position opened.
Below the log MT4.

0 19:02:00.339 '1772219': order sell market 0.23 EURUSD sl: 1.73336 tp: 0.00000
0 19:02:00.443 '1772219': order was opened : #300738526 sell 0.23 EURUSD at 1.13336 sl: 1.73336 tp: 0.00000
0 19:02:00.491 '1772219': order sell market 0.31 EURAUD sl: 1.57389 tp: 0.00000
0 19:02:00.593 '1772219': order was opened : #300738527 sell 0.31 EURAUD at 1.56789 sl: 1.57389 tp: 0.00000
0 19:02:00.645 '1772219': order sell market 0.23 GBPUSD sl: 1.30369 tp: 0.00000
0 19:02:00.750 '1772219': order was opened : #300738528 sell 0.23 GBPUSD at 1.29769 sl: 1.30369 tp: 0.00000
0 19:07:19.511 '1772219': close order #300738526 sell 0.01 EURUSD at 1.13336 sl: 1.73336 tp: 0.00000 at price 0.00000
0 19:07:19.611 '1772219': order #300738526 sell 0.01 EURUSD at 1.13336 sl: 1.73336 tp: 0.00000 closed at price 1.13380
0 19:07:19.611 '1772219': remainder of order #300738526 was opened : #300740237 sell 0.22 EURUSD at 1.13336 sl: 1.73336 tp: 0.00000
0 19:07:19.707 '1772219': close order #300738527 sell 0.01 EURAUD at 1.56789 sl: 1.57389 tp: 0.00000 at price 0.00000
0 19:07:19.820 '1772219': order #300738527 sell 0.01 EURAUD at 1.56789 sl: 1.57389 tp: 0.00000 closed at price 1.56815
0 19:07:19.820 '1772219': remainder of order #300738527 was opened : #300740238 sell 0.30 EURAUD at 1.56789 sl: 1.57389 tp: 0.00000
0 19:07:19.896 '1772219': close order #300738528 sell 0.01 GBPUSD at 1.29769 sl: 1.30369 tp: 0.00000 at price 0.00000
0 19:07:20.061 '1772219': order #300738528 sell 0.01 GBPUSD at 1.29769 sl: 1.30369 tp: 0.00000 closed at price 1.29824
0 19:07:20.061 '1772219': remainder of order #300738528 was opened : #300740239 sell 0.22 GBPUSD at 1.29769 sl: 1.30369 tp: 0.00000

Re: Entry and Exit different LotAmount [Re: tradingest] #474861
11/09/18 18:37
11/09/18 18:37
Joined: Feb 2018
Posts: 236
Italy
tradingest Offline OP
Member
tradingest  Offline OP
Member

Joined: Feb 2018
Posts: 236
Italy
I noticed that within MT4 the opened size it's different respect the message shown in Zorro.
The link to see this difference.
Why?

Re: Entry and Exit different LotAmount [Re: tradingest] #474865
11/10/18 00:56
11/10/18 00:56
Joined: Feb 2018
Posts: 236
Italy
tradingest Offline OP
Member
tradingest  Offline OP
Member

Joined: Feb 2018
Posts: 236
Italy
with the same code with some broker MT4 close whole position with other no. Why?

thanks for the support

Re: Entry and Exit different LotAmount [Re: tradingest] #474870
11/10/18 08:01
11/10/18 08:01
Joined: Jul 2000
Posts: 27,977
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,977
Frankfurt
That's the journal log. The MQ4 log is under MQL4/Logs. But anyway, can you contact Support? They'll request some files and will walk you through a specific test for finding the problem.

Re: Entry and Exit different LotAmount [Re: jcl] #474875
11/10/18 11:03
11/10/18 11:03
Joined: Feb 2018
Posts: 236
Italy
tradingest Offline OP
Member
tradingest  Offline OP
Member

Joined: Feb 2018
Posts: 236
Italy
Hi jcl,

thanks for help me, for me is very important to understand this.
Below the log recover in the path MQL4/Logs like your indication

0 19:02:00.339 Zorro EURUSD,Daily: Open EURUSD 0.23@1.1334 stop 1.7334 slp 10 magic 42380 factor 10
2 19:02:00.443 Zorro EURUSD,Daily: open #300738526 sell 0.23 EURUSD at 1.13336 sl: 1.73336 ok
0 19:02:00.491 Zorro EURUSD,Daily: Open EURAUD 0.31@1.5679 stop 1.5739 slp 10 magic 42380 factor 10
2 19:02:00.593 Zorro EURUSD,Daily: open #300738527 sell 0.31 EURAUD at 1.56789 sl: 1.57389 ok
0 19:02:00.645 Zorro EURUSD,Daily: Open GBPUSD 0.23@1.2977 stop 1.3037 slp 10 magic 42380 factor 10
2 19:02:00.750 Zorro EURUSD,Daily: open #300738528 sell 0.23 GBPUSD at 1.29769 sl: 1.30369 ok
0 19:07:19.511 Zorro EURUSD,Daily: Close [EURUSD:S8526] 0.01@1.13380
2 19:07:19.611 Zorro EURUSD,Daily: close #300738526 sell 0.01 EURUSD at 1.13336 sl: 1.73336 at price 1.13380
0 19:07:19.611 Zorro EURUSD,Daily: Remaining [EURUSD:S237] 0.22@1.1338
0 19:07:19.707 Zorro EURUSD,Daily: Close [EURAUD:S8527] 0.01@1.56810
2 19:07:19.820 Zorro EURUSD,Daily: close #300738527 sell 0.01 EURAUD at 1.56789 sl: 1.57389 at price 1.56815
0 19:07:19.820 Zorro EURUSD,Daily: Remaining [EURAUD:S238] 0.3@1.5681
0 19:07:19.896 Zorro EURUSD,Daily: Close [GBPUSD:S8528] 0.01@1.29820
2 19:07:20.061 Zorro EURUSD,Daily: close #300738528 sell 0.01 GBPUSD at 1.29769 sl: 1.30369 at price 1.29824
0 19:07:20.061 Zorro EURUSD,Daily: Remaining [GBPUSD:S239] 0.22@1.2982

What does means uninit reason 9?

Thanks for the support. Without to close whole position I can't go live

Re: Entry and Exit different LotAmount [Re: tradingest] #474876
11/10/18 11:04
11/10/18 11:04
Joined: Feb 2018
Posts: 236
Italy
tradingest Offline OP
Member
tradingest  Offline OP
Member

Joined: Feb 2018
Posts: 236
Italy
if you need of other information ask me


Moderated by  Petra 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1