code: private void fromFileButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fromFileButtonActionPerformed
          // Allow user to select a file, and read input data from that file
          JFileChooser fileChooser = new JFileChooser();
          if (fileChooser.showOpenDialog(this) == JFileChooser.APPROVE_OPTION) {
              File file = fileChooser.getSelectedFile();
              try {
                  dataInputArea.setText(OpenFile.ReadFile(file, false));
              } catch (Exception e) {
                  System.out.println("Cannot read from file" + fileChooser.getSelectedFile().toString());
              }
          }
      }
docs: GEN-LAST:event_resetButtonActionPerformed