Пример #1
0
 public void EliminarDocente()
 {
     try
     {
         this.GetDocente();
         DocenteActual.State = BusinessEntity.States.Deleted;
         DocCursoLog.Save(DocenteActual);
     }
     catch
     {
         Response.Write("<script>alert('Error al eliminar la comisión')</script>");
     }
 }
Пример #2
0
 public void GetDocente()
 {
     try
     {
         GridViewRow row = gdvDocCur.SelectedRow;
         int         ID  = int.Parse(row.Cells[0].Text);
         DocenteActual = DocCursoLog.GetOne(ID);
     }
     catch (Exception ex)
     {
         ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "alertMessage", "alert('" + ex.Message + "')", true);
     }
 }
Пример #3
0
 public void EliminarAsignacion()
 {
     try
     {
         int             ID             = (int)dgvDocCur.SelectedRows[0].Cells["ID"].Value;
         Docentes_Cursos DocCursoActual = DocCursoLog.GetOne(ID);
         DocCursoActual.State = BusinessEntity.States.Deleted;
         DocCursoLog.Save(DocCursoActual);
     }
     catch
     {
         MessageBox.Show("Error al eliminar la asignación del docente al curso, intente nuevamente", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }