Could anyone help with this task?
I use daily graph and I'd like to programm strategy which open a position on Daily OPEN if this OPEN is lower then previous CLOSE.
But it always open the position next day.
I guess that this code is completely wrong but I have change it many times and I am feel really lost...
if (BarsInProgress == 1) { openPrice = GetCurrentAsk(); } if (BarsInProgress == 0) { if (Time[0].DayOfWeek == DayOfWeek.Friday) { lastFridayClose = Close[0]; tradeProceed = false; BackColor = Color.LightSkyBlue; } if (openPrice < lastFridayClose && !tradeProceed) { tradeProceed = true; EnterLong(1, 1, "Long: 1min"); BackColor = Color.Chartreuse; } }
Martin
Comment