Hello,
I mean the sum of all closed profitable trades. I don't want to consider open trades in the calculation.
Posts made by Jnmr1
-
RE: Gross profitposted in Questions & Answers
-
Gross profitposted in Questions & Answers
Hello,
Is their a way to calculate gross profit in MQL5? (profit without subtracting loss)Thank you
James -
terminal variables?posted in Questions & Answers
Hello, Im wondering if I can use terminal variables ie gvar0 as an input for lot size for example. so instead of having 0.01 as the input put gvar0. that way i can change the lot size on all of my running ea's at once?
-
RE: new block please?posted in Questions & Answers
Ok, the only issue i see with this is that there is no way to point to the last trade opened. if you look at the screen shot you will see that because there is both a buy and sell that have taken place both sets of loop blocks will pass. an example of the logic im looking for would look something like this:
look at last order opened regardless of weather it is currently running or closed, if it is a buy position then continuously pass.  -
new block please?posted in Questions & Answers
Hello,
I am currently using "pass once" & "reset" blocks in my EA. the problem is if the EA restarts, they have no memory of their state before the restart. would it be possible to create a block that looks at the attributes of the last trade (open or closed) for a given currency pair (buy, sell, etc). The "Check type (last closed)" block will not work because there is a 50/50 chance that the last trade will still be open.thank you
James -
Once per blockposted in Bug Reports
It does not appear that the values from Set "Current Market" for next blocks pass to Once per bar block. the values pass to all other blocks, including blocks connected below once per bar block
-
RE: MQL5. check profit (unrealized)posted in Bug Reports
@fxdreema Thank you for fixing it. It worked yesterday, I was going nuts thinking it was a mistake on my part.
-
MQL5. check profit (unrealized)posted in Bug Reports
there is a new problem with the block " check profit (unrealized)"
When it is attached to any block and then I compile the code MetaEditor I get the errors "'TradesTotal' - function not defined HMA.mq5" and "'TradeSelectByIndex' - function not defined HMA.mq5"
I have never had this problem beforeJames
-
New block? Pleaseposted in Questions & Answers
would it be possible to create a new MQL5 block that closes the position with the most loss?
Thank you
James -
RE: New function?posted in Questions & Answers
it looks like the ticket number would have to be the identifier as it appears that there are no position numbers in the strategy tester
-
RE: New function?posted in Questions & Answers
For all EA's. Maybe just a block that can be placed in an EA
-
New function?posted in Questions & Answers
Hello,
would it be possible to create a new block that allows me to manually close trades while in the strategy tester. possibly a small GUI window that you enter the trade number that you want to close and a button to close the trade?Thanks
James -
RE: "check profit (period of time)" modification please?posted in Questions & Answers
maybe modify the block so that it always rounds the resault down to the nearest dollar?
-
RE: "check profit (period of time)" modification please?posted in Questions & Answers
Ok I have been testing. The problem I see is that I need to be able to get a time shifted balance (1 hour ago, 1 day ago, 1 month ago, etc) otherwise it is always short of the goal. $1000 gained 2% today which is $1020, 1020*0.02=20.4 which is $0.40 short of the goal. I don't know of any way to overcome this other then to get the AccountBalance() from yesterday.
Thanks
James

