public void updateBhavData(string bhavFile, string mtoFile) { int count = 0; var date = DateTime.Parse("01/01/2018"); NseStockData nse = new NseStockData(); var stockData = nse.updateBhavData(bhavFile, mtoFile); if (stockData != null) { count += dB.AddDailyStockData(stockData, null, date); } if (count != 0) { StockMarket.cache.Clear(); } }
public int updateBhavData(DateTime date) { int count = 0; NseStockData nse = new NseStockData(); var result = nse.updateBhavData(date); if (result.stockData != null) { count += dB.AddDailyStockData(result.stockData, result.circuitBreakerData, date); } if (count != 0) { StockMarket.cache.Clear(); } return(count); }