I'm working wit NJ8 and doing a lot of strategies and backtesting there. Now i'm trying something timebased but hit a brick wall. to As the title suggests, i'm trying to trigger at certain times, which can fall outside of trading hours. Sundays and holidays seem to be the issue here, where no signal is triggert.
for example:
DayOfTheMonth = 1;
if (Time[0] == DayOfTheMonth )
{
EnterLong(Convert.ToInt32(DefaultQuantity), @"");
}
I would have expected to get 12 entries (due to pending orders when outside trading hours). Didn´t happen.
Tried to iterate it by reading the day:
i.e. if (Time[0] == DayOfWeek.Sunday ) {...AddDays(1) } or {DayOfTheMonth+1}
as well as stuff like if (TradingHours.Holidays.ContainsKey(currentDay.Date )) {...}
but had no effect.
Any ideas what i am doing wront or how to make it right so i'll get my n-triggers?
Thanks a lot for your help.

Comment