private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton1ActionPerformed
        // TODO add your handling code here:
        try {

            material = new Material(this.jTextField1.getText(),  this.jTextField2.getText(),this.jTextArea2.getText(),Float.parseFloat(this.jTextField3.getText()),this.jTextField4.getText(),String.valueOf(this.jComboBox1.getSelectedItem()));
            if( this.jTextField1.getText().length() <= 0 || this.jTextField3.getText().contains(" ")  ){
            JOptionPane.showMessageDialog(null,"Tiene que ingresar minimo ID de material");
            }else{
            material.Ingresar_material(material);

          this.dispose();
          bandera = true;
            }

        } catch (SQLException ex) {
            Logger.getLogger(VIngresar_Material.class.getName()).log(Level.SEVERE, null, ex);
        }

    }//GEN-LAST:event_jButton1ActionPerformed