private void raBETWEEN_CheckedChanged(object sender, EventArgs e) { groupBox3.Visible = true; groupBox4.Visible = false; if (raOR.Checked == true) { dataGridView1.DataSource = order.ORDER_TOTAL_BETWEEN(Convert.ToDateTime(dt.Value.ToShortDateString()), Convert.ToDateTime(dt1.Value.ToShortDateString())); CalculateTotalAmount1(); } else if (raPOR.Checked == true) { dataGridView1.DataSource = order.PURCHASE_TOTAL_BETWEEN(Convert.ToDateTime(dt.Value.ToShortDateString()), Convert.ToDateTime(dt1.Value.ToShortDateString())); CalculateTotalAmount1(); } else { dataGridView1.DataSource = order.ITEM_TOTAL_BETWEEN(Convert.ToDateTime(dt.Value.ToShortDateString()), Convert.ToDateTime(dt1.Value.ToShortDateString())); CalculateTotalAmount2(); } }