Have a Daily Strategy that I need to add tick resolution so to enter a trade on a close of the Daily Close Bar ... The primary bars are Daily bars and the secondary bars are tick... as follows;
protected override void Initialize()
{
CalculateOnBarClose = false;
Add(PeriodType.Tick, 1);
}
Then in on bar update I have the wrapped the code with
if (BarsInProgress == 0)
{
//Daily logic
}
but the strategy executions on my Daily Chart have dissapeared?
Here is what is in Daily Logic...
if (Close[0] > ema50) //LONG
{
if (RSI(Close, 2, 1)[0]<35)
{
EnterLong(NumContract, "Long Entry ema50 S1");
//EnterLong(1,NumContract, "Long Entry ema50 S1"); // submit to the second bars index (index = 1)
Print("Date and Time "+Time[0]+" In we go");
}
}
if (RSI(Close, 2, 1)[0]>65)
{
ExitLong("Long Entry ema50 S1");
//ExitLong(1,NumContract, "Long Exit ema50 S1","Long Entry ema50 S1"); // submit to the second bars index (index = 1)
}
If I comment out the "Add(PeriodType.Tick, 1);" in the initialisation section I see the orders but when I add this in the orders dissapear?
I used to see the orders going in to the market on the open of the next open bar ... What I am trying to do is for the orders to execute on the close of a Daily Bar use tick interval i.e what is underlined
Any ideas why this is not working for me?
Thanks

Comment