NewLong is being set correctly and plotted correctly but the Alert is not being generated? Any ideas?
if ((DateTime.Now.AddDays(-1).Date ==Time[0].Date) && (ToTime(DateTime.Now) <= ToTime(9, 30, 00)))// Yesterdays date Premarket(before 9,30,00)
{
index=0;
if (((Trend[(index+1)]==0) && (Trend[index]==1) ) || ((Trend[(index+1)]==-1) && (Trend[index]==1) ))
{
NewLong.Set(1);
Alert("GoingLong", NinjaTrader.Cbi.Priority.High, "New Long Position Initiated today...", "Connected.wav", 300, Color.Green, Color.White);
}
else
{
NewLong.Set(0);
}
Comment