private void btnDiscSalvar_Click(object sender, EventArgs e) { String nome, descricao; int cargaHor, idDisc; idDisc = Convert.ToInt32(txtCodDisc.Text); nome = txtDiscNome.Text; cargaHor = Convert.ToInt32(txtDiscCargaHor.Text); descricao = txtDescricao.Text; discEnt.Nome = nome; discEnt.IdDisciplina = idDisc; discEnt.Carga_Hor = cargaHor; discEnt.Descricao = descricao; discDAO.salvarDisc(discEnt); }