Exemple #1
0
        private void buttonNovoManutencao_Click(object sender, EventArgs e)
        {
            frmManutencaoAlterar manutencaoAlterar = new frmManutencaoAlterar(null, Accao.Inserir);
            DialogResult         dr = manutencaoAlterar.ShowDialog();

            if (dr == DialogResult.Yes)
            {
                pesquisa("%");
            }
        }
Exemple #2
0
        private void buttonAlterarManutencao_Click(object sender, EventArgs e)
        {
            if (dataGridViewManutencao.SelectedRows.Count == 0)
            {
                MessageBox.Show("Nenhum Manutencao Selecionada");
                return;
            }


            if ((dataGridViewManutencao.SelectedRows[0].DataBoundItem as Manutencao) == null)
            {
                MessageBox.Show(" linha vazia Selecionada");
                return;
            }
            Manutencao datagriV = dataGridViewManutencao.SelectedRows[0].DataBoundItem as Manutencao;

            frmManutencaoAlterar manutencaoAlterar = new frmManutencaoAlterar(datagriV, Accao.Alterar);
            DialogResult         dr = manutencaoAlterar.ShowDialog();

            if (dr == DialogResult.Yes)
            {
                pesquisa("%");
            }
        }