private void makefile(){
        if(pType.getText().length() > 0 && prio.getText().length() == 1 && tot.getText().length() > 0 && prescrArea.getText().length() > 0){
            if(notes.getText().equals("") || notes.getText().equals("Inserisci le tue note."))
                    MainPanel.prescr.setNotes("-");
            else MainPanel.prescr.setNotes(notes.getText());
            MainPanel.prescr.setPresType(pType.getText());
            MainPanel.prescr.setPriority(prio.getText().charAt(0));
            MainPanel.prescr.setTotal(Integer.parseInt(tot.getText()));
            MainPanel.prescr.setPrescriptions(prescrArea.getText());
            MainPanel.currEx.deletePrescription(MainPanel.prescr.getTruename());
            MainPanel.currEx.sendPrescriptionData(MainPanel.prescr);
        } else
            System.out.println("Inserisci i campi giusti");    
    }