Java - ¿Cómo guardar datos double en un archivo txt y mostrarlos? - JAVA Jframe

 
Vista:
Imágen de perfil de Johann

¿Cómo guardar datos double en un archivo txt y mostrarlos? - JAVA Jframe

Publicado por Johann (3 intervenciones) el 11/11/2022 05:18:10
JAVA JFrame

Tengo una duda sobre como puedo guardar lo que son mis datos altura, peso y el imca (imc actual) en formato double en mi archivo y poderlos mostrar.

Adjunto mi código de java, realizado en JFrame:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
package procto.final2;
 
 
import java.io.File;
import java.io.FileInputStream;
import java.io.FileWriter;
import java.io.IOException;
import java.io.PrintWriter;
import static java.lang.System.exit;
import java.util.Formatter;
import java.util.Properties;
import javax.swing.JOptionPane;
import javax.swing.table.DefaultTableModel;
 
 
 
 
public class Frm_PacientesDatos extends javax.swing.JFrame {
 
    String barra = File.separator;
    String ubicacion = System.getProperty("user.dir")+barra+"Registros"+barra;
 
    File contenedor = new File(ubicacion);
    File [] registros = contenedor.listFiles();
 
    String [] titulos = {"Codigo","Nombre","Apellido","Edad","Telefono","Altura","Peso","Imci","Imca"};
    DefaultTableModel mdlTabla = new DefaultTableModel(null, titulos);
 
    private void Crear(){
        String archivo = txtCodigo.getText()+".registros";
        File crea_ubicacion = new File(ubicacion);
        File crea_archivo = new File(ubicacion+archivo);
 
 
       if(txtCodigo.getText().equals("")){
            JOptionPane.showMessageDialog(rootPane, "NO HAY CODIGO");
       }//cierra if
 
       else{
 
            try{
               if(crea_archivo.exists()){
                   JOptionPane.showMessageDialog(rootPane, "El registro ya existe");
               }//cierra if
 
               else{
 
                   crea_ubicacion.mkdirs();
                   Formatter crea = new Formatter(ubicacion+archivo);
                   crea.format("%s\r\n%s\r\n%s\r\n%s\r\n%s\r\n%.2f\r\n%.2f\r\n%.2f\r\n%.2f", "Codigo="+txtCodigo.getText(),
                           "Nombre="+txtNombre.getText(), "Apellido="+txtApellido.getText(),
                           "Edad="+txtEdad.getText(), "Telefono="+txtTelefono.getText(),
                           "Altura="+txtAltura.getText(), "Peso="+txtPeso.getText(),
                           "Imci="+txtImci.getText(), "Imca="+txtImca.getText());
                   /*
                   Double altura;
                   Double peso;
                   Double imca = peso/(altura*altura);*/
 
                   crea.close();
                   JOptionPane.showMessageDialog(rootPane, "Archivo del paciente guardado");
 
                   jComboBox.removeAllItems();
                   registros = contenedor.listFiles();
                   MostrarCombo();
                   ActualizarTabla();
 
               }//cierra else
 
            }//cierra try
 
 
 
            catch(Exception e){
               JOptionPane.showMessageDialog(rootPane, "NO SE PUDO GUARDAR EL ARCHIVO");
 
            }//cierra catch
 
       }//cierra else
 
    }
 
 
    private void Mostrar(){
        File url = new File(ubicacion+txtCodigo.getText()+".registros");
 
        if(txtCodigo.getText().equals("")){
            JOptionPane.showMessageDialog(rootPane, "Indique el ID para Mostar");
        }//cierra if
 
        else{
 
            if(url.exists()){
 
                try{
 
                    FileInputStream fis = new FileInputStream(url);
                    Properties mostrar = new Properties();
                    mostrar.load(fis);
 
                    txtNombre.setText(mostrar.getProperty("Nombre"));
                    txtApellido.setText(mostrar.getProperty("Apellido"));
                    txtEdad.setText(mostrar.getProperty("Edad"));
                    txtTelefono.setText(mostrar.getProperty("Telefono"));
                    txtAltura.setText(mostrar.getProperty("Altura"));
                    txtPeso.setText(mostrar.getProperty("Peso"));
                    txtImci.setText(mostrar.getProperty("Imci"));
                    txtImca.setText(mostrar.getProperty("Imca"));
 
                }//cierra try
 
                catch(Exception e){
 
                }//cierra catch
 
            }//cierra if2
 
 
 
            else{
                JOptionPane.showMessageDialog(rootPane, "Ese registro no existe");
 
            }//cierra else2
 
        }//cierra else
    }
 
 
    private void Editar(){
        File url = new File(ubicacion+txtCodigo.getText()+".registros");
 
        if(txtCodigo.getText().equals("")){
            JOptionPane.showMessageDialog(rootPane, "Indique el registro que desa editar");
        }//cierra if
 
        else{
 
            if(url.exists()){
                try {
 
                    FileWriter permite_escrito = new FileWriter(ubicacion+txtCodigo.getText()+".registros");
 
                    String codigo = "Codigo=";
                    String nombre = "Nombre=";
                    String apellido = "Apellido=";
                    String edad = "Edad=";
                    String telefono = "Telefono=";
                    String altura = "Altura=";
                    String peso = "Peso=";
                    String imci = "Imci=";
                    String imca = "Imca=";
 
                        PrintWriter guardar = new PrintWriter(permite_escrito);
                        guardar.println(codigo+txtCodigo.getText());
                        guardar.println(nombre+txtNombre.getText());
                        guardar.println(apellido+txtApellido.getText());
                        guardar.println(edad+txtEdad.getText());
                        guardar.println(telefono+txtTelefono.getText());
                        guardar.println(altura+txtAltura.getText());
                        guardar.println(peso+txtPeso.getText());
                        guardar.println(imci+txtImci.getText());
                        guardar.println(imca+txtImca.getText());
 
                        permite_escrito.close();
 
                        JOptionPane.showMessageDialog(rootPane, "Registro editado correctamente");
                        ActualizarTabla();
 
                }//cierra try
 
                catch(Exception e){
                    JOptionPane.showMessageDialog(rootPane, "error"+e);
 
                }//cierra catch
 
            }//cierra if
 
            else{
                JOptionPane.showMessageDialog(rootPane, "El registro no existe");
            }//cierra else
 
        }//cierra else
 
 
    }
 
 
    private void Eliminar(){
        File url = new File(ubicacion+txtCodigo.getText()+".registros");
        String botones [] = {"Eliminar", "Cancelar"};
 
        if(txtCodigo.getText().equals("")){
            JOptionPane.showMessageDialog(rootPane, "Indique cual registro desa elminar");
 
        }//cierra if
 
        else{
            if(url.exists()){
 
                try{
 
                    FileInputStream cerrar = new FileInputStream(url);
                    cerrar.close();
                    System.gc();
 
                    int seguro = JOptionPane.showOptionDialog(rootPane,
                            "¿Esta seguro de elminar el regsitro? "+txtCodigo.getText(),
                            "Eliminacion", 0, 0, null, botones, null);
 
                    if(seguro == JOptionPane.YES_OPTION){
 
                        url.delete();
                        JOptionPane.showMessageDialog(rootPane, "Regsitro eliminado");
                        jComboBox.removeItem(txtCodigo.getText());
                        ActualizarTabla();
                    }//cierra if3
 
 
                    if(seguro == JOptionPane.NO_OPTION){
 
 
                    }//cierra if4
 
                }//cierra try
 
                catch(Exception e){
 
                }//cierra catch
 
            }//cierra if2
 
            else{
 
            }//cierra else2
 
        }//cierra else
 
    }
 
 
    private void MostrarCombo() {
        for(int i=0; i<registros.length; i++){
            jComboBox.addItem(registros[i].getName().replace(".registros", ""));
        }
    }
 
 
 
    private void RegTabla(){
 
        for(int i=0; i<registros.length; i++){
 
            File url = new File(ubicacion+registros[i].getName());
 
            try{
                FileInputStream fis = new FileInputStream(url);
                Properties mostrar = new Properties();
                mostrar.load(fis);
 
                String filas [] = {registros[i].getName().replace(".registros", ""),
                    mostrar.getProperty("Nombre"),mostrar.getProperty("Apellido"),mostrar.getProperty("Edad"),
                    mostrar.getProperty("Telefono"),mostrar.getProperty("Altura"),mostrar.getProperty("Peso"),
                    mostrar.getProperty("Imci"),mostrar.getProperty("Imca")};
 
               mdlTabla.addRow(filas);
 
            }//cierra try
 
            catch(Exception e){
 
            }//cierra catch
 
        }//cierra for
 
        tblReporte.setModel(mdlTabla);
 
    }
 
 
 
    public Frm_PacientesDatos() {
        initComponents();
        setLocationRelativeTo(null);
        MostrarCombo();
        RegTabla();
 
    }
 
 
    private void ActualizarTabla(){
 
        registros = contenedor.listFiles();
 
        mdlTabla.setRowCount(0);
 
        RegTabla();
    }
 
 
 
 
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">
    private void initComponents() {
 
        jLabel1 = new javax.swing.JLabel();
        txtCodigo = new javax.swing.JTextField();
        jLabel2 = new javax.swing.JLabel();
        jComboBox = new javax.swing.JComboBox<>();
        txtNombre = new javax.swing.JTextField();
        jLabel3 = new javax.swing.JLabel();
        txtApellido = new javax.swing.JTextField();
        jLabel7 = new javax.swing.JLabel();
        txtEdad = new javax.swing.JTextField();
        jLabel4 = new javax.swing.JLabel();
        txtTelefono = new javax.swing.JTextField();
        jLabel5 = new javax.swing.JLabel();
        txtAltura = new javax.swing.JTextField();
        jLabel6 = new javax.swing.JLabel();
        txtPeso = new javax.swing.JTextField();
        jLabel8 = new javax.swing.JLabel();
        txtImci = new javax.swing.JTextField();
        jLabel9 = new javax.swing.JLabel();
        txtImca = new javax.swing.JTextField();
        btnGuardar = new javax.swing.JButton();
        btnMostrarDatos = new javax.swing.JButton();
        btnSalir = new javax.swing.JButton();
        jScrollPane1 = new javax.swing.JScrollPane();
        tblReporte = new javax.swing.JTable();
        btnEditar = new javax.swing.JButton();
        btnEliminar = new javax.swing.JButton();
        jLabel11 = new javax.swing.JLabel();
        jLabel10 = new javax.swing.JLabel();
 
        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        getContentPane().setLayout(new org.netbeans.lib.awtextra.AbsoluteLayout());
 
        jLabel1.setForeground(new java.awt.Color(0, 0, 0));
        jLabel1.setText("CÓDIGO:");
        getContentPane().add(jLabel1, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 10, -1, -1));
 
        txtCodigo.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                txtCodigoActionPerformed(evt);
            }
        });
        getContentPane().add(txtCodigo, new org.netbeans.lib.awtextra.AbsoluteConstraints(100, 10, 178, -1));
 
        jLabel2.setForeground(new java.awt.Color(0, 0, 0));
        jLabel2.setText("NOMBRE:");
        getContentPane().add(jLabel2, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 53, -1, -1));
 
        jComboBox.setBackground(new java.awt.Color(121, 205, 218));
        jComboBox.addComponentListener(new java.awt.event.ComponentAdapter() {
            public void componentShown(java.awt.event.ComponentEvent evt) {
                jComboBoxComponentShown(evt);
            }
        });
        jComboBox.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jComboBoxActionPerformed(evt);
            }
        });
        getContentPane().add(jComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(285, 10, 110, -1));
        getContentPane().add(txtNombre, new org.netbeans.lib.awtextra.AbsoluteConstraints(100, 50, 178, -1));
 
        jLabel3.setForeground(new java.awt.Color(0, 0, 0));
        jLabel3.setText("APELLIDO:");
        getContentPane().add(jLabel3, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 90, -1, 20));
        getContentPane().add(txtApellido, new org.netbeans.lib.awtextra.AbsoluteConstraints(100, 90, 178, -1));
 
        jLabel7.setForeground(new java.awt.Color(0, 0, 0));
        jLabel7.setText("EDAD:");
        getContentPane().add(jLabel7, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 130, -1, 40));
 
        txtEdad.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                txtEdadActionPerformed(evt);
            }
        });
        getContentPane().add(txtEdad, new org.netbeans.lib.awtextra.AbsoluteConstraints(100, 140, 179, -1));
 
        jLabel4.setForeground(new java.awt.Color(0, 0, 0));
        jLabel4.setText("TELÉFONO:");
        getContentPane().add(jLabel4, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 190, -1, 40));
        getContentPane().add(txtTelefono, new org.netbeans.lib.awtextra.AbsoluteConstraints(100, 200, 178, -1));
 
        jLabel5.setForeground(new java.awt.Color(0, 0, 0));
        jLabel5.setText("ALTURA:");
        getContentPane().add(jLabel5, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 250, -1, 40));
 
        txtAltura.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                txtAlturaActionPerformed(evt);
            }
        });
        getContentPane().add(txtAltura, new org.netbeans.lib.awtextra.AbsoluteConstraints(100, 260, 178, -1));
 
        jLabel6.setForeground(new java.awt.Color(0, 0, 0));
        jLabel6.setText("PESO:");
        getContentPane().add(jLabel6, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 310, -1, 40));
        getContentPane().add(txtPeso, new org.netbeans.lib.awtextra.AbsoluteConstraints(100, 320, 178, -1));
 
        jLabel8.setForeground(new java.awt.Color(0, 0, 0));
        jLabel8.setText("IMC INICIAL:");
        getContentPane().add(jLabel8, new org.netbeans.lib.awtextra.AbsoluteConstraints(440, 10, -1, 20));
 
        txtImci.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                txtImciActionPerformed(evt);
            }
        });
        getContentPane().add(txtImci, new org.netbeans.lib.awtextra.AbsoluteConstraints(540, 10, 120, -1));
 
        jLabel9.setForeground(new java.awt.Color(0, 0, 0));
        jLabel9.setText("IMC ACTUAL:");
        getContentPane().add(jLabel9, new org.netbeans.lib.awtextra.AbsoluteConstraints(440, 50, -1, 20));
        getContentPane().add(txtImca, new org.netbeans.lib.awtextra.AbsoluteConstraints(540, 50, 120, -1));
 
        btnGuardar.setBackground(new java.awt.Color(83, 216, 153));
        btnGuardar.setText("GUARDAR");
        btnGuardar.setToolTipText("");
        btnGuardar.setMargin(new java.awt.Insets(0, 0, 0, 0));
        btnGuardar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnGuardarActionPerformed(evt);
            }
        });
        getContentPane().add(btnGuardar, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 380, 90, 40));
 
        btnMostrarDatos.setBackground(new java.awt.Color(83, 216, 153));
        btnMostrarDatos.setText("MOSTRAR DATOS");
        btnMostrarDatos.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnMostrarDatosActionPerformed(evt);
            }
        });
        getContentPane().add(btnMostrarDatos, new org.netbeans.lib.awtextra.AbsoluteConstraints(130, 380, 140, 40));
 
        btnSalir.setBackground(new java.awt.Color(83, 216, 153));
        btnSalir.setFont(new java.awt.Font("Dialog", 1, 24)); // NOI18N
        btnSalir.setText("Salir");
        btnSalir.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnSalirActionPerformed(evt);
            }
        });
        getContentPane().add(btnSalir, new org.netbeans.lib.awtextra.AbsoluteConstraints(830, 680, 140, 60));
 
        tblReporte.setBackground(new java.awt.Color(121, 205, 218));
        tblReporte.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
 
            },
            new String [] {
 
            }
        ));
        tblReporte.setSelectionForeground(new java.awt.Color(0, 0, 0));
        tblReporte.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                tblReporteMouseClicked(evt);
            }
        });
        jScrollPane1.setViewportView(tblReporte);
 
        getContentPane().add(jScrollPane1, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 430, 770, 330));
 
        btnEditar.setBackground(new java.awt.Color(83, 216, 153));
        btnEditar.setText("EDITAR");
        btnEditar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnEditarActionPerformed(evt);
            }
        });
        getContentPane().add(btnEditar, new org.netbeans.lib.awtextra.AbsoluteConstraints(300, 380, 90, 40));
 
        btnEliminar.setBackground(new java.awt.Color(83, 216, 153));
        btnEliminar.setText("ELIMINAR");
        btnEliminar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnEliminarActionPerformed(evt);
            }
        });
        getContentPane().add(btnEliminar, new org.netbeans.lib.awtextra.AbsoluteConstraints(430, 380, 100, 40));
 
        jLabel11.setIcon(new javax.swing.ImageIcon(getClass().getResource("/procto/final2/Tabla de obesidad2.png"))); // NOI18N
        jLabel11.setPreferredSize(new java.awt.Dimension(200, 200));
        getContentPane().add(jLabel11, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 80, 460, 290));
 
        jLabel10.setIcon(new javax.swing.ImageIcon(getClass().getResource("/procto/final2/Clinica imagen.jpeg"))); // NOI18N
        getContentPane().add(jLabel10, new org.netbeans.lib.awtextra.AbsoluteConstraints(-110, 0, 1190, 760));
 
        pack();
    }// </editor-fold>
 
    private void txtCodigoActionPerformed(java.awt.event.ActionEvent evt) {
 
    }
 
    private void btnGuardarActionPerformed(java.awt.event.ActionEvent evt) {
 
        Crear();
    }
 
    private void btnMostrarDatosActionPerformed(java.awt.event.ActionEvent evt) {
 
        Mostrar();
    }
 
    private void btnSalirActionPerformed(java.awt.event.ActionEvent evt) {
 
       JOptionPane.showMessageDialog(rootPane, "¡GRACIAS POR CONSULTAR SU MASA CORPORAL CON NOSOTROS!"+"\n\nPASE UN FELIZ DIA" );
       System.exit(0);
 
    }
 
    private void txtAlturaActionPerformed(java.awt.event.ActionEvent evt) {
        // TODO add your handling code here:
    }
 
    private void txtImciActionPerformed(java.awt.event.ActionEvent evt) {
        // TODO add your handling code here:
    }
 
    private void btnEditarActionPerformed(java.awt.event.ActionEvent evt) {
 
        Editar();
    }
 
    private void btnEliminarActionPerformed(java.awt.event.ActionEvent evt) {
 
        Eliminar();
    }
 
    private void tblReporteMouseClicked(java.awt.event.MouseEvent evt) {
 
    }
 
    private void txtEdadActionPerformed(java.awt.event.ActionEvent evt) {
        // TODO add your handling code here:
    }
 
    private void jComboBoxComponentShown(java.awt.event.ComponentEvent evt) {
        // TODO add your handling code here:
    }
 
    private void jComboBoxActionPerformed(java.awt.event.ActionEvent evt) {
 
        String copiar = (String) jComboBox.getSelectedItem();
        txtCodigo.setText(copiar);
        Mostrar();
 
    }
 
 
 
 
    public static void main(String args[]) {
        /* Set the Nimbus look and feel */
        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html
         */
        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(Frm_PacientesDatos.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(Frm_PacientesDatos.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(Frm_PacientesDatos.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(Frm_PacientesDatos.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }
        //</editor-fold>
        //</editor-fold>
 
        /* Create and display the form */
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                new Frm_PacientesDatos().setVisible(true);
            }
        });
    }
 
    // Variables declaration - do not modify
    private javax.swing.JButton btnEditar;
    private javax.swing.JButton btnEliminar;
    private javax.swing.JButton btnGuardar;
    private javax.swing.JButton btnMostrarDatos;
    private javax.swing.JButton btnSalir;
    private javax.swing.JComboBox<String> jComboBox;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel10;
    private javax.swing.JLabel jLabel11;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JLabel jLabel7;
    private javax.swing.JLabel jLabel8;
    private javax.swing.JLabel jLabel9;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JTable tblReporte;
    private javax.swing.JTextField txtAltura;
    private javax.swing.JTextField txtApellido;
    private javax.swing.JTextField txtCodigo;
    private javax.swing.JTextField txtEdad;
    private javax.swing.JTextField txtImca;
    private javax.swing.JTextField txtImci;
    private javax.swing.JTextField txtNombre;
    private javax.swing.JTextField txtPeso;
    private javax.swing.JTextField txtTelefono;
    // End of variables declaration
}


imagen_2022-11-10_221738253
imagen_2022-11-10_221757234
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder