private void Listar() { dgvMaterias.AutoGenerateColumns = false; try { this.dgvMaterias.DataSource = ml.GetAllSinPlan(); } catch (NotFoundException ex) { MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } catch (CustomException ex) { MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } catch (Exception ex) { MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } }
private void LoadMaterias() { this.dgvMaterias.AutoGenerateColumns = false; dgvMaterias.DataSource = ml.GetAllSinPlan(); }