Why did ProOrder stop here?
Forums › ProRealTime English forum › ProOrder support › Why did ProOrder stop here?
- This topic has 5 replies, 3 voices, and was last updated 3 years ago by Mike Boorman.
-
-
08/31/2020 at 9:09 AM #143028
Hello folks,
Hopefully you can help me here.
My program stopped with an open trade as soon as the market opened on Sunday night/Monday morning. The only information I can get from PRT is “order cancelled” – there is no other explanation. This same code has carried trades overnight before so I can’t understand why it couldn’t handle the next market open (the gap was in favour of the trade so it shouldn’t have triggered any exit conditions). I’ve attached a screengrab of the market and the code. Could anyone explain why the program stopped itself?
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485//-------------------------------------------------------------------------// Main code : /////Live ZUS30 zig A28 II//-------------------------------------------------------------------------DEFPARAM CumulateOrders = Falseslmove = 5longentry1= close crosses over SuperTrend[1.5,34]shortentry1= close crosses under SuperTrend[1.5,34]longexit1= slpriceshortexit1= slpricezig1start=101000zig1end=105000zig2start=124000zig2end=132000zig3start=152800zig3end=160800zig4start=0zig4end=0if intradaybarindex=0 thenentryflag=0endifif time =zig1start thenentryflag=1endifif time =zig1end thenentryflag=0endifif time =zig2start thenentryflag=1endifif time =zig2end thenentryflag=0endifif time =zig3start thenentryflag=1endifif time =zig3end thenentryflag=0endifif time =zig4start thenentryflag=1endifif time =zig4end thenentryflag=0endifif not onmarket and entryflag=1 and lowest[4] <= lowest[45] and longentry1 thenBUY 1 PERPOINT AT MARKETentryflag=0sl= AverageTrueRange[14](close) * 7slprice = close - slendifif not onmarket and entryflag=1 and highest[4] >= highest[45] and shortentry1 thenSellshort 1 perpoint at marketentryflag=0sl= AverageTrueRange[14](close) * 7slprice = close + slendifif longonmarket and high - sl > slprice + slmove thenslprice = high - slendifif longonmarket and close < longexit1 thensell at marketendifif shortonmarket and low + sl < slprice - slmove thenslprice = low + slendifif shortonmarket and close > shortexit1 thenexitshort at marketendifSet stop ploss 30008/31/2020 at 9:46 PM #14310109/01/2020 at 8:38 AM #143111The “order cancelled” is coming from your broker, not from ProOrder. I think that it is surely in relation with the gap that happen on that particular candlestick.. slippage? A market order should not be cancelled BTW.. so I don’t really know what happened here. If this happened on a live account, then you should ask your broker with the ticket order number for them to investigate.
1 user thanked author for this post.
09/01/2020 at 9:07 AM #143115GraHal:
This was in real life, not demo mode. As it was, it only cost me a small amount of money, but if the market had kept running onwards in my favour I’d have been mightily pissed off!
Nicolas:
The gap would make sense as a reason if it was a gap downwards and caused my trailing stop to trigger, but it was upwards and in my favour because it was a long trade. I’ve got no profit take on there, so it should have just carried on as normal.
1 user thanked author for this post.
09/01/2020 at 9:14 AM #14311609/10/2020 at 2:35 PM #143877I just got this back from PRT: “Your ProRealTime platform tried to adjust your stop according to your code, as the market had just opened.
However, the broker rejected the orders because they considered the market as closed.”I still haven’t had a reply from IG about this. Very strange that IG sent the message that the market had opened, but then decided it was closed once it started processing my stop request. Why would a bar start but then stop? When does that ever happen?!? None of this makes sense at all.
-
AuthorPosts
Find exclusive trading pro-tools on