private void btnDeletar_Click(object sender, EventArgs e) { PecasBLL pecaBll = new PecasBLL(); PecasDTO pecaDto = new PecasDTO(); //pecaDto.PEC_ID = int.Parse(txtcodigo.Text); pecaBll.Excluir(pecaDto); MessageBox.Show("Peça excluída com sucesso!", "Atenção", MessageBoxButtons.OK, MessageBoxIcon.Information); //txtcodigo.Text = ""; txtfabricante.Text = ""; txtnome.Text = ""; txtqtde.Text = ""; }