Esempio n. 1
0
        private void btnGuardar_Click(object sender, EventArgs e)
        {
            try
            {
                Ficha           auxFicha           = new Ficha();
                DetalleFicha    detalle            = new DetalleFicha();
                NegocioFicha    auxNegocioFicha    = new NegocioFicha();
                NegocioPaciente auxNegocioPaciente = new NegocioPaciente();
                NegocioDetalle  auxNegocioDetalle  = new NegocioDetalle();

                auxFicha.IdFicha   = int.Parse(this.txtIdFicha.Text);
                auxFicha.IdDetalle = int.Parse(this.txtIdDetalle.Text);
                auxFicha.RutPac    = int.Parse(this.txtRutPaciente.Text);

                auxNegocioPaciente.buscarPaciente(int.Parse(this.txtRutPaciente.Text));

                detalle.IdDetalle    = int.Parse(this.txtIdDetalle.Text);
                detalle.IdEnfermedad = Convert.ToInt32(boxEnfermedad.SelectedIndex);
                detalle.Descripcion  = this.txtDescripcion.Text;
                detalle.FCita        = monthCalendar1.SelectionStart;

                auxNegocioDetalle.grabarDetalle(detalle);
                auxNegocioFicha.grabarFicha(auxFicha);
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message + " Mensaje Sistema");
            }
        }//fin btn guardar
Esempio n. 2
0
        private void btnBuscar_Click(object sender, EventArgs e)
        {
            NegocioDetalle auxNegocioDetalle = new NegocioDetalle();
            DetalleFicha   detalle           = new DetalleFicha();

            detalle.FCita = pickerFecha.Value;

            // auxNegocioDetalle.actualizarFecha
        }
Esempio n. 3
0
 private void btnBuscar_Click(object sender, EventArgs e)
 {
     try
     {
         if (string.IsNullOrEmpty(this.txtRutPaciente.Text))
         {
             try
             {
                 NegocioDetalle auxDetalle = new NegocioDetalle();
                 dataGridView1.DataSource = auxDetalle.listarDetalle();
             }
             catch (Exception ex)
             {
                 MessageBox.Show("Mensaje Sistema" + ex.Message);
             }
         }//FIN IF
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message + "Mensaje Sistema");
     }
 }