Dislikedthe ordersend error due to price digit I think..anyway..good it works for you...Is it profitable?Ignored
I have a little rules here:
Inserted Code
if(TimeDayOfWeek(cur_time) == 0 || TimeDayOfWeek(cur_time) == 6) { text = StringConcatenate("nTrading on Saturday/Sunday (local time) is disabled, so no trading today.",text); is_trading_time = false; }
And I don't want it in this rule:
Inserted Code
if(!TradeOnMonday && day_of_week <= 1) { text = StringConcatenate("nTrading on Monday is disabled, so no trading today.",text); is_trading_time = false; }
Edit:
Fixed with:
Inserted Code
extern bool DontTradeOnMondayBefore6 = True; if (DontTradeOnMondayBefore6 && day_of_week <= 1 && Hour() <= 6) { text = StringConcatenate("nTrading on Monday before 6:00 is disabled, so no trading today.",text); is_trading_time = false; }