Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (alibaba, vicknick), 1,379 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Updating pending trades with MaxLong/MaxShort #484525
11/07/21 17:17
11/07/21 17:17
Joined: Aug 2021
Posts: 101
M
MegaTanker Offline OP
Member
MegaTanker  Offline OP
Member
M

Joined: Aug 2021
Posts: 101
enterLong/enterShort calls are supposed to update pending trades when the limit of MaxLong/MaxShort (both = 1 in my script) is reached but it doesn't seem to work for me unless EntryTime is at the default of 1. But in that case, entries are missed after one bar and the following enter call doesn't really update the existing trade, it rather replaces the trade that just expired, so it only looks as though it is updating the trade. When I set EntryTime to something higher so that the trade is actually still alive upon the next enter call, the trade is not updated. I checked using the STEPWISE feature where the pending trade is shown in a window. I am printing the Entry value before the enter call with a watch statement to confirm that this is indeed changing as desired, but the following enter call doesn't change the pending trade's Entry to the new Entry even though it is different. (Same for the take profit)

Am I missing something?

Re: Updating pending trades with MaxLong/MaxShort [Re: MegaTanker] #484526
11/07/21 17:26
11/07/21 17:26
Joined: Sep 2003
Posts: 929
Spirit Offline

Moderator
Spirit  Offline

Moderator

Joined: Sep 2003
Posts: 929
MaxLong,Short updates pending trades? I think not.

Re: Updating pending trades with MaxLong/MaxShort [Re: MegaTanker] #484527
11/07/21 17:33
11/07/21 17:33
Joined: Aug 2021
Posts: 101
M
MegaTanker Offline OP
Member
MegaTanker  Offline OP
Member
M

Joined: Aug 2021
Posts: 101
Yeah now I see the manual only mentions open trades so that explains it


Moderated by  Petra 

Powered by UBB.threads™ PHP Forum Software 7.7.1