private void cmdBaoCao_Click(object sender, EventArgs e) { try { string manhacungcap = Utility.DoTrim(txtNhacungcap.myCode); if (manhacungcap == "") { manhacungcap = "ALL"; } DataTable m_dtReport = BAOCAO_THUOC.ThuocBaocaoThuoctheonhacungcap(chkByDate.Checked ? dtFromDate.Value : Convert.ToDateTime("01/01/1900"), chkByDate.Checked ? dtToDate.Value : globalVariables.SysDate, Utility.Int32Dbnull(cboKho.SelectedValue), manhacungcap, KIEU_THUOC_VT, Utility.Bool2byte(chkPhieuvay.Checked)); Utility.SetDataSourceForDataGridEx(grdList, m_dtReport, true, true, "1=1", ""); if (m_dtReport.Rows.Count <= 0) { Utility.ShowMsg("Không tìm thấy dữ liệu", "Thông báo", MessageBoxIcon.Warning); return; } string FromDateToDate = Utility.FromToDateTime(dtFromDate.Text, dtToDate.Text); VNS.HIS.UI.Baocao.thuoc_baocao.baocao_nhapthuoctheo_nhacungcap(m_dtReport, KIEU_THUOC_VT == "THUOC"?"thuoc_baocao_nhapkho_theonhacungcap":"vt_baocao_nhapkho_theonhacungcap", baocaO_TIEUDE1.TIEUDE, dtNgayIn.Value, FromDateToDate); } catch (Exception) { } }