Indicator to EA problem
You should adjust your TP & SL to work with both 4 digit and 5 digit Brokers.
You should also check the return values from the OrderSend() function calls to make sure it has worked,
read this: What are Function return values ? How do I use them ?
Your function
bool isTrade () // VERIFICATION SI UN TRADE EST EN COURS
is not looking if the open trades are trades from EA.
if you have open another trade on your account this EA won't trade at all
Check the trades with the function
nobody? =(
patient
extern double HourDayStart = 6; //+------------------------------------------------------------------+ int start() { //---- New Day datetime now = Time[0], bod = now - now % 86400, // Beginning of the day HourDay = bod + HourDayStart * 3600; // 6:00 //---- return(0); }
Thank you for your answer, actually the problem is that it does not respect the time to trade. Here starting from 6:00, it does not take into account the highest and lowest
Forgot your code and tell what's the EA should do?
I'm sorry, but I'm a disaster in programming (no logic lol =(), I'm reading the manual, I will not understand much in fact that is why I turned to you
You are not disaster in programming. I'm just asking what do you want to do?
I want an EA based on breakouts. For example:
I setting a time zone in hours, I mark the highest and the lowest.
I expect a candle closes above for a buy signal, below for a sell signal.
The stop loss is placed on the highest for a sell signal, and vice versa for a buy signal.
Gain: should be equal to the difference between the highest and the lowest, with a trailing stop that is triggered once the target is reached to protect gains.
I want ..
I setting ..
I expect ..
Hi everybody,
I'm a beginner with automated trading. I hope to have your help because I'm stuck.
I'm trying to convert this indicator to EA.
This is a breakout strategy based on an interval in hours.
My code does not work, it does not respect the buy signal
ps: sorry for my English, I'm French