private void CargarFormulario(int id)
        {
            this.persona                 = this.LogicaPersona.TraerUno(id);
            this.txtNombre.Text          = this.persona.Nombre;
            this.txtApellido.Text        = this.persona.Apellido;
            this.txtCorreoE.Text         = this.persona.Email;
            this.txtDireccion.Text       = this.persona.Direccion;
            this.txtTelefono.Text        = this.persona.Telefono;
            this.txtFechaNacimiento.Text = this.persona.FechaNacimiento.ToString("dd/MM/yyyy");
            this.txtLegajo.Text          = this.persona.Legajo.ToString();
            switch (persona.Tipo)
            {
            case Personas.TipoPersona.Alumno:
                this.ddlTipoPersona.SelectedIndex = 0;
                break;

            case Personas.TipoPersona.Profesor:
                this.ddlTipoPersona.SelectedIndex = 1;
                break;

            case Personas.TipoPersona.Administrativo:
                this.ddlTipoPersona.SelectedIndex = 2;
                break;

            default:
                this.ddlTipoPersona.SelectedIndex = 0;
                break;
            }
            this.ddlPlan.SelectedValue = Convert.ToString(LogicaPlan.TraerUno(persona.IDPlan).ID);
        }
Ejemplo n.º 2
0
 private void CargarFormulario(int id)
 {
     this.Plan                          = LogicaPlan.TraerUno(id);
     this.idTextBox.Text                = this.Plan.ID.ToString();
     this.descripcionTextBox.Text       = this.Plan.Descripcion;
     this.ddlEspecialidad.SelectedValue = new LogicaEspecialidad().TraerUno(Plan.IdEspecialidad).ID.ToString();
 }