private void jButtonSaveParamActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButtonSaveParamActionPerformed
        // TODO add your handling code here:
        if(txtBddPath != null || txtDecotePath != null || txtDevisPath != null || txtFacturePath!= null || txtFolderPath != null || txtIdBdd != null || txtMdpBdd != null || txtMesurePath != null){
            // on creer le noeud racine
            Element racine = null;
            //un objec jdom document
            Document document = null;
            // on creer une instance de saxbuilder
            SAXBuilder sxb = new SAXBuilder();

            //Recupération des valeurs de parametre et modification de celle-ci
            try {
                String path = System.getProperty("user.dir" );
                document = sxb.build(new File(path + "/src/files/param.xml"));
                racine = document.getRootElement();
                List lstParam = racine.getChildren("param");

                //Iterator pour parcourir la list
                Iterator ite = lstParam.iterator();

                String paramName;
                String paramPath;

                while(ite.hasNext()){
                    Element curent = (Element) ite.next();
                    //recupere values
                    paramName = curent.getAttributeValue("name").toString();
                    paramPath = curent.getAttributeValue("pathName").toString();
                    
                    //modifier values
                    if(paramName.contains("bddPath"))
                        curent.setAttribute("pathName", txtBddPath.getText());
                    if(paramName.contains("bddUser"))
                        curent.setAttribute("pathName", txtIdBdd.getText());
                    if(paramName.contains("bddPass"))
                        curent.setAttribute("pathName", txtMdpBdd.getText());
                    if(paramName.contains("factureModel"))
                        curent.setAttribute("pathName", txtFacturePath.getText());
                    if(paramName.contains("devisModel"))
                        curent.setAttribute("pathName", txtDevisPath.getText());
                    if(paramName.contains("mesureModel"))
                        curent.setAttribute("pathName", txtMesurePath.getText());
                    if(paramName.contains("decoteModel"))
                        curent.setAttribute("pathName", txtDecotePath.getText());
                    if(paramName.contains("folderCommandePath"))
                        curent.setAttribute("pathName", txtFolderPath.getText());

                }
                // Enregistre les modifications
                XMLOutputter sortie = new XMLOutputter(Format.getPrettyFormat());
                sortie.output(document, new FileOutputStream(path + "/src/files/param.xml"));
                
                JOptionPane.showMessageDialog(this, "Nouveau paramètre pris en comptes");
                dispose();

            } catch (JDOMException ex) {
                Logger.getLogger(Parametres.class.getName()).log(Level.SEVERE, null, ex);
            } catch (IOException ex) {
                Logger.getLogger(Parametres.class.getName()).log(Level.SEVERE, null, ex);
            }
        }else{
            JOptionPane.showMessageDialog(this, "Tous les chemin doivent êtres renseignés");
        }
    }//GEN-LAST:event_jButtonSaveParamActionPerformed