Hi,
I am trying to do the following:
No need for all that. For a buy, profit increases when the market goes up. So if Close[0] < Close[1] then current profit < profit at candle close[1].
So do you think you'll make any money if you close all trades the moment market drops one point below Close[1]?
No need for all that. For a buy, profit increases when the market goes up. So if Close[0] < Close[1] then current profit < profit at candle close[1].
So do you think you'll make any money if you close all trades the moment market drops one point below Close[1]?
I was thinking the same logic but isn't it possible that close[0] < close[1] but current profit remains the same? Meaning, doesn't the market have to move a certain amount in order for current profit to change?
Here's an approximation using blocks but it's not as accurate as comparing current profit to previous profit. Clearly, this needs some custom code using an array but I'm not sure how to do it: http://fxdreema.com/shared/3d0EGJopb
re: effectiveness of this strategy, I'm not looking to close all trades when market level drops but only those trades whose current profit is 0.00. Essentially, the idea is to prevent these trades from slipping back into the minus :)
thanks for your responses :)
1. I assume if OrderCloseTime = 0 then OrderClosePrice will take the value at the current tick?
What do DeltaPerLot and OrderLots mean?
2. Is there a way to move stop loss to OrderOpenPrice even if current market price is less than broker's minimum s/l away from open price? I have tried this using ea but it always says "Too short s/l requested, minimum will be taken".
- OrderClosePrice is Bid (Buy) or Ask (Sell) on open orders
- DeltaPerLot is the change in profit per lot per change in price.
- Waht is OrderLots()? RTFM!
- You can set the stop loss anywhere you want (subject to Requirements and Limitations in Making Trades - Appendixes - MQL4 Tutorial)
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hi,
I am trying to do the following:
Loop through open trades. For each open trade in loop:
Thanks in advance for your help :)