Hi Fx Dreema!
In "trade statistics" -> "profict factor" give me -1
Can you please check ?
Thank you
Dave
Hi Fx Dreema!
In "trade statistics" -> "profict factor" give me -1
Can you please check ?
Thank you
Dave
Hi, have you found any solution to this? Sometimes “modify stop” blocks go for the grey outcome and I can’t get the last error.. and I’m struggling to understand what’s going on...
Also happen using "Market Properties" function like here
https://fxdreema.com/shared/SBYjoBXkb
Thanks
Hi @fxDreema
when trying to retrive values of a candle from EA running on a different pair the digits number are wrong.
You can try this one. I attached on XAUUSD trying to read the open price of NZDCHF and give me 0.63 instead of 0.63445
https://fxdreema.com/shared/iPDfBR3X
Hope you can fix it.
Thanks
Dave
Sorry i didn't see your reply..
very strange, these are my resaults..
i tried with different account and metatraders..
?????
i covered some numbers just to help you see the random pattern..

Hi @fxDreema
Can you please check the Hour Filter? when the filter is set between 00:00 it seems don't work right..
In the project below the filter is from 22:00 to 00:59 but it work only until 23:59 as you see in the image..
Not a big problem now, i just split the time in two parts but for the future... i'm sure i'll forget it next time!
thanks
https://fxdreema.com/shared/ArQptM05e

Hope it will help, i made this script https://fxdreema.com/shared/S6V8yaZkc
Tried on two real accounts with 5 an 100 trades, in both case the results are RANDOM!!! 
Ok @fxDreema i will investigate.
I thought you were in holidays so i decided in the meantime to wrote a function inside FxDreema Studio to order the history.
Works like a charme!
Never used FxDreema Studio but is a really great addon! Wow!
Thanks for it, as always!
Hi @fxDreema
i wonder about the "for each Closed Trade" function..
I use it to analyze the last n trades profit using the method "Newest to Oldest"
looking at the mq4 code, here mine two questions:
i thought the function returns the last n trades ordered from Close Time, is that right?
Or it returns the last n trades opened and already closed?
probably i'm wrong but it looks like the "For each Trade" model does not sort by ticket or date
and looking around on forums i found this two statements:
From MQL4 Guide link text
"Consecutive selection of orders using the SELECT_BY_POS parameter returns information in the sequence in which it was received from the trading server. Sorting of the resulting list of orders cannot be guaranteed."
and from link text
"I found that in both 'trade pool' and 'history pool', the list is sorted by time the trade is opened."
"When back testing this seems to work as you might expect with orders entering the list sequentially. When done in live accounts you are better off considering the ordering as random and sorting it yourself."
"By the way, the OrdersHistory also contains balance transfers, identifiable as OrderSymbol()==""
If you have 5 or 6 orders in your history you may be lulled in a false sense of security and think you have the pattern figured out. I just checked it this evening to make sure and of 150 trades in the history there are not just a few out of date order, but lots. The first errors didn't appear until 30 items into the list."
"There is no explicit documentation of the sorting order of this list, so better considering it as random sorted, as Dabbler suggested. It can depend on brokers also.
Perhaps there is a more experienced programmer here, who can point the documentation of this. But, if not, when the sequence of list is critical, you should build a custom array of it, then sort yourself."
With all that said, how can i reliable check the last n trades closed (ordered by oldest closing time)?
Thank you
Dave
Hi @fxDreema
Something is breaking here..
suddenly the block "modify stops" that i regularly use,
stop working with just sell orders.
It calculates a TP on the wrong side, just above the price, not under..
What happens?!
Here a test EA
https://fxdreema.com/shared/wGumiZumb
Dave