private void jButton9ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton9ActionPerformed
        liceu.Administrator admin = new liceu.Administrator(usernameSecretar.getText(), parolaSecretar.getText(),ncSecretar.getText(),cnpSecretar.getText(),"Secretar");
        admin.addUser();
        usernameSecretar.setText("");
        parolaSecretar.setText("");
        ncSecretar.setText("");
        cnpSecretar.setText("");
        
        int i;
        BufferedReader fisier;
        try {
            fisier = new BufferedReader(new FileReader("credentials"));
            listModelSecretari.clear();
            ArrayList<String> vector = new ArrayList<>();
            for(String line; (line = fisier.readLine())!= null;){
                vector.add(line);                  
            }            
            for(i=0;i<vector.size();i=i+5){
                if(vector.get(i+4).equals("Secretar"))
                   listModelSecretari.addElement(vector.get(i));
            }
        } catch (FileNotFoundException ex) {
            Logger.getLogger(Administratorapp.class.getName()).log(Level.SEVERE, null, ex);
        } catch (IOException ex) {
            Logger.getLogger(Administratorapp.class.getName()).log(Level.SEVERE, null, ex);
        }
        
        
    }//GEN-LAST:event_jButton9ActionPerformed