LexarG56

Generation

generate functionThu, 20 Jul 2023

JComboBox con 5 model en un ActionPerformed para un boton registrar

private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) { String valor = (String) jComboBox1.getSelectedItem(); String valor2 = (String) jComboBox2.getSelectedItem(); String valor3 = (String) jComboBox3.getSelectedItem(); String valor4 = (String) jComboBox4.getSelectedItem(); String valor5 = (String) jComboBox5.getSelectedItem(); JOptionPane.showMessageDialog(null,"Usted ha seleccionado lo siguiente: \n" + "1: " + valor + "\n2: " + valor2 + "\n3: " + valor3 + "\n4: " + valor4 + "\n5: " + valor5); }

Questions about programming?Chat with your personal AI assistant