Ejemplo n.º 1
0
        private void Loaddata()
        {
            try
            {
                dt_ql = new DataTable();
                dt_ql.Clear();

                DataSet ql = dbQuanLy.LayQuanLy();
                dt_ql = ql.Tables[0];
                dgv_nql.DataSource = dt_ql;
                dgv_nql.AutoResizeColumns();
                dgv_nql_CellClick(null, null);
            }
            catch
            {
                MessageBox.Show(error.ToString());
                MessageBox.Show("Có lỗi xảy ra,không lấy được dữ liệu table TieuDe!");
            }
        }