Total Orders Count both Pending order and running trades
-
@Lacone I'm still confused

There's a block, trades count and another pending order count, is there a way to use the results from these blocks in a formula? So I can simply add them up to get the total order
-
There are 3 ways to create/modify variables:
Manually.
Formula blocks.
Modify Variables blocks....But I'm curious, how do you open 30 trades all at once so the count of less than 30 doesn't trigger...?
Steep, frustrating learning curve I know....:-))
-
t does not need to be added in a formula, as the counter in the separate trees counts the pending orders and open positions together.
This means that no matter where the counter is used, with each pass (activating from the output of the "Counter Buy" variable), one is always added (+1). -
@Morpheus_0 yes oo... A steep frustrating curve.
The thing is, only pending orders are opened. No trade is opened. 15 buy pending orders and 15 sell pending orders all at once... So the only trades that gets opened is when the pending order gets triggered -
@Lacone so what about when they are closed?
-
I see....and then so how do you end up with less than 30 Trades/Orders....?
-
@Morpheus_0 more so, even if the count is triggered... I intend to add a block to check how the last order was closed, if it wasn't closed by trailing stop, then nothing would happen. I know how to do this one... I just need to be able to know how to count total orders for now. Whether by custom mql code as that appears a lil straight for me or by using the results from the check trade count and pending order count blocks,
This variable stuff gets me really confused


-
@Morpheus_0 because not all of the trade gets triggered at once.. hence trades are in profit, trailing stop is activated
However due to slippage. And even during the visual test I notice that when the stop loss is modified and then hit immediately, the trades remain undeleted (the remaining pending order)
-
After closing, the variable (counter) is set back to zero
-
Well in the On Trade tab you could try a Trade Closed block and connect that to a Close Trades and a Delete Pending Orders blocks....
That should mean that when 1 trade gets closed, everything else gets closed/deleted....
Sry if I'm off the mark here....*
-
@Morpheus_0 thank you, I'll look into it. However I just got an idea, if there's a way to check trade closed within a specific period of time (say 1 minute) then that would solve all the problem.
-
@Lacone not all close at once
-
On the on trade tab you can use purple blocks to start an action.
-
@jstap How do you mean by start an action please
-
@jstap how do you mean start an action? What kinda action can I start that can help me with this issue, either with checking total trade number or by checking time of closed trades to see if they are within 'n' period of time, say 1 minute
-
What I mean is on trade purple block for the tree start, with any blocks under that you want to do something, to act on the purple block action to commit any other block actions underneath
-
@jstap - Have a look at the shared link I posted on the first page and see if I'm correct*