i have a little problem with my EA which is not opening buystop/sellstop positions. The condition is quite simple, i also tried it with several indicator just to see if it opens any sellstop/buystop order but it doesnt. THe EA is in the attachement, and the code for opening the positions is below. I just want to open a sellstop position if the Close price is below the Low price of the 8th previous candle. Very simple condition but it doesnt open positions:
Maybe somebody of you sees the problem ?!
Thank you in advance
Hi, Check your lot and maybe this could help you, add this to manage on your Trade Volume
The highlighted - should be a +
Print your error when an OrderSend fails. Add as much information as you need to the print, entry price , SL, TP, Ask etc.
Thank you very much for the tip ! I did print the error, but not all of them unfortunately.
Ok i might found the reason. In the begining of the script i have the input int Pips = 500;.
as i opened this topic i had set it to 10, then i doesnt work. If i set it to 500 it sets sell/buy stop positions but closes it immediately. Also it doesnt seem that the ea doesnt open the stop positions due to the condition.
To be honest i dont really understand the code from the stop positions
what does (Pips*Point) calculate ?
You are showing code where you have not corrected the error that I have already pointed out and still with no error checking.
ok now I know what it calculates. Was a bad question I admit it. I found it easily of course. I also got my buystop sellstop positions work correctly now. Thanks everyone for help.