コード例 #1
0
 private void btnNuevoTurno_Click(object sender, EventArgs e)
 {
     if (turnos == null)
     {
         turnos             = new frmAgregarTurno();
         turnos.MdiParent   = this.MdiParent;
         turnos.FormClosed += new FormClosedEventHandler(TurnosFormClosed);
         turnos.Show();
     }
 }
コード例 #2
0
        private void btnAgregar_Click(object sender, EventArgs e)
        {
            frmAgregarTurno turnos = Owner as frmAgregarTurno;

            Cliente cliente = new Cliente();

            cliente = (Cliente)dgvClientes.CurrentRow.DataBoundItem;

            turnos.txtIDcliente.Text   = cliente.id.ToString();
            turnos.txtnombrecli.Text   = cliente.nombre;
            turnos.txtapellidocli.Text = cliente.apellido;
            this.Close();
        }
コード例 #3
0
        private void btnAgregar_Click(object sender, EventArgs e)
        {
            frmAgregarTurno turnos = Owner as frmAgregarTurno;

            Animal animal = new Animal();

            animal = (Animal)dgvMascotas.CurrentRow.DataBoundItem;

            turnos.txtIDmascota.Text    = animal.id.ToString();
            turnos.txtnombremasc.Text   = animal.nombre;
            turnos.txtapellidomasc.Text = animal.apellido;
            turnos.txtraza.Text         = animal.raza.nombre;
            turnos.txtEspecie.Text      = animal.especie;
            this.Close();
        }
コード例 #4
0
 private void TurnosFormClosed(object sender, EventArgs e)
 {
     turnos = null;
 }