Historic data , "day" interval not giving any response which was working earlier

vishwas
var fromDtInit = new DateTime(DateTime.Now.Year,
DateTime.Now.Month,
DateTime.Now.Day
);

var toDtInit = new DateTime(DateTime.Now.Year,
DateTime.Now.Month,
DateTime.Now.Day,
);

resultList = OrderManager.GetHistoricalData(fromDt, toDt, symbolToken, Constants.INTERVAL_DAY);

this was working till now, suddenly it has stopped working. Other intervals are working.
can you please help?
  • rakeshr
    DateTime.Now.Day
    You need to request with the correct start and end day. If you are looking for current-day data, you need to send to date as next day.
  • sgsaran
    Till now I sent date format as from 2024-07-04+00:00:00 to 2024-07-04+23:59:00. It worked till last week. But now it returns empty array. I have to send previous date to get data. But it is wrong as per the date which I give. Look at the attached image. I requested from=2024-07-03+00:00:00&to=2024-07-04+23:59:00. But it didn't return 3rd date candle.






Sign In or Register to comment.