protected void img_DEL_Click(object sender, ImageClickEventArgs e) { cUDGDFRESERVACIONNegocios cReservacion = new cUDGDFRESERVACIONNegocios(0, "", 0, ""); cUDGDFCURSONegocios cCurso = new cUDGDFCURSONegocios(0, "", 0, ""); try { // Elimina el curso cCurso.ID_CURSO = int.Parse(lbl_ID_CURSO.Text); cCurso.Eliminar(); // Elimina la reservacion cReservacion.ID_RESERVACION = int.Parse(lbl_ID_RESERVACION.Text); cReservacion.Eliminar(); } catch (Exception) { // Redirecciona hacia mensaje de error Response.Redirect("~/frmNotificacion.aspx?sol=0&op=notInc", true); } // Redirecciona a la confirmación Response.Redirect("~/Confirmacion.aspx", true); }
protected void img_DEL_Click(object sender, ImageClickEventArgs e) { cUDGDFRESERVACIONNegocios cReservacion = new cUDGDFRESERVACIONNegocios(0, "", 0, ""); cUDGDFEVENTONegocios cEvento = new cUDGDFEVENTONegocios(0, "", 0, ""); try { // Elimina el evento cEvento.ID_EVENTO = int.Parse(lbl_ID_EVENTO.Text); cEvento.Eliminar(); // Elimina la reservacion cReservacion.ID_RESERVACION = int.Parse(lbl_ID_RESERVACION.Text); cReservacion.Eliminar(); } catch (Exception) { Response.Redirect("~/frmNotificacion.aspx?sol=0&op=notInc", true); } Response.Redirect("~/Confirmacion.aspx", true); }