Пример #1
0
 private void Agregar()
 {
     try
     {
         var frm = new MntInventarioInicialForm(ViewModelList);
         frm.ShowDialog();
     }
     catch (Exception ex)
     {
         MessageBox.Show(string.Format("Ocurrió un error al agregar, mensaje de error: {0}", ex.Message)
                         , "Agregar", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
Пример #2
0
 private void Modificar()
 {
     try
     {
         var viewModel = (InventarioInicialViewModel)inventarioInicialViewModelBindingSource.Current;
         var frm       = new MntInventarioInicialForm(viewModel, ViewModelList);
         frm.ShowDialog();
     }
     catch (Exception ex)
     {
         MessageBox.Show(string.Format("Ocurrió un error al modificar, mensaje de error: {0}", ex.Message)
                         , "Modificar", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }