@SuppressWarnings("CallToThreadDumpStack")
    private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton1ActionPerformed
        if(emp != null && !emp.isVisible()){
            lPane.remove(emp);
            emp = null;
        }
        if (emp == null) {
            emp = new FrmCadEmpresa();
            Validacoes v = new Validacoes();
            v.posicao(this, emp);
            lPane.add(emp);
            try {
                emp.setSelected(true);
            } catch (PropertyVetoException ex) {
                ex.printStackTrace();
            }
        }else{
            emp.toFront();
        }

    }//GEN-LAST:event_jButton1ActionPerformed