コード例 #1
0
        private void btnNovo_Click(object sender, EventArgs e)
        {
            var frm = new FormCadastroPagamento();

            if (frm.ShowDialog() != DialogResult.OK)
            {
                return;
            }
            CarregarGridView();
        }
コード例 #2
0
 private void btnEditar_Click(object sender, EventArgs e)
 {
     if (gridView.SelectedRows.Count > 0)
     {
         var idd = Convert.ToInt32(gridView.SelectedRows[0].Cells[0].Value);
         var obj = new TipoPagamentoDAO().BuscarPorId(idd);
         var frm = new FormCadastroPagamento(obj);
         if (frm.ShowDialog() != DialogResult.OK)
         {
             return;
         }
         CarregarGridView();
     }
 }