aaa gb

aaa gb

  • NA
  • 24
  • 311

Display records filtered by shift(day or night)

Sep 16 2018 6:08 PM
i have sales system that has two shifts(day and night) i need to display records in ReportViewer filtered by shift to calculate sales of each shift At Spesific Day(am using datetimepicker to select dates and comboBox to select the shift).
I Have Tried This :
  1. private void shiftcomboBox_SelectedIndexChanged(object sender,EventArgse)
  2. {
  3.  this.sellsTableAdapter.FillBy1(this.kafDataSet4.sells, Convert.ToDateTime(dateTimePicker1.Value.ToShortDateString()), Convert.ToDateTime(dateTimePicker2.Value.ToShortDateString()), Convert.ToString(comboBox1.SelectedItem)); this.reportViewer1.RefreshReport();
  4. }  
i passed the dates from datetimepickers and it works but my problem is the second shift ends after midnight so that extra hours will not be included in the report so that gives wrong calculation of mony.
 

Answers (1)