hi i have a problem with thid can some one help me

import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import java.awt.Dimension;
import java.util.*;
import java.io.*;
import java.awt.Font;


class FileStudent extends JFrame implements ActionListener{

private BufferedReader bufferedReader;
private FileReader fileReader;
private JFileChooser fileChooser;
private Button searchButton, gemButton, studvolButton;
private JTextField fileField;
// private path;
// private file selectedFile ;

public static void main (String []args){
FileStudent frame = new FileStudent();
frame.setSize(600, 150);
frame.createGUI();
frame.show();
}

private void createGUI(){
setDefaultCloseOperation (EXIT_ON_CLOSE);
Container window = getContentPane();
window.setLayout(new FlowLayout());



//searchButton = new Button ("Search for file");
//window.add(searchButton);
//searchButton.addActionListener(this);



gemButton = new Button ("Gemiddelde Vakken");
window.add(gemButton);
gemButton.addActionListener(this);



studvolButton = new Button ("Student met voldoende");
window.add(studvolButton);
studvolButton.addActionListener(this);

fileField = new JTextField (40);
window.add(fileField);


}

public void actionPerformed(ActionEvent e){

int resultaat;
if (e.getSource()==gemButton){

fileChooser = new JFileChooser();
resultaat = fileChooser.showOpenDialog(this);

if(resultaat == JFileChooser.APPROVE_OPTION)
{

File selFile = fileChooser.getSelectedFile();
String path = selFile.getPath();
fileField.setText(
selFile.getAbsolutePath());

try {
fileReader = new FileReader (path);
bufferedReader = new BufferedReader(fileReader);
// fileReader = new FileReader (path);
//inFile = new BufferedReader(fileReader);
String file;
file = bufferedReader.readLine();

if (file != null){
double gem, gem2;
double tot, tot2;
double res, res2;
double ant, ant2;

gem=0.0 ; gem2 =0.0;
tot=0.0 ; tot2 =0.0;
res=0.0 ; res2 =0.0;
ant=0.0 ; ant2=0.0;

while (file != null){

//Token

StringTokenizer tokens = new StringTokenizer(file, ",");
String studentnumInFile = tokens.nextToken();
String naamInFile = tokens.nextToken();
String vaknaamInFile = tokens.nextToken();
String resultInFile = tokens.nextToken();

if ( vaknaamInFile.equals("JAVA1")){
//found = true;
//fileArea.setText(tokens.nextToken());

res = Double.parseDouble(resultInFile);
tot = tot + res;
ant += 1;
}

if ( vaknaamInFile.equals("JAVA2")){
res2 = Double.parseDouble(resultInFile);
tot2 = tot2 + res2 ;
ant2 += 1;
}
file = bufferedReader.readLine();

}
gem = tot / ant;
gem2= tot2/ant2;

JOptionPane.showMessageDialog(null, "Gemiddelde java1 is " + gem + "\n" + "Gemiddelde java2 is " + gem2);

bufferedReader.close();
}
else
JOptionPane.showMessageDialog(null,"File is leeg");

}

catch (Exception ae){
JOptionPane.showMessageDialog(null,"Error reading file"+ ae.toString());
}
}
}
// public void actionPerformed(ActionEvent e){
else if (e.getSource()== studvolButton){
fileChooser = new JFileChooser();
resultaat = fileChooser.showOpenDialog(this);

if(resultaat==JFileChooser.APPROVE_OPTION){

File selFile = fileChooser.getSelectedFile();
String path = selFile.getPath();


try{
fileReader = new FileReader(path);
bufferedReader = new BufferedReader(fileReader);

String file;
file = bufferedReader.readLine();

if(file != null)
{
String studvak1="";
String studvak2="";
String nl = "\n";

while(file != null)
{
// JOptionPane.showMessageDialog(null, fl);
StringTokenizer tokens = new StringTokenizer( file, " ,");

String studentnumInFile = tokens.nextToken();
String nameInFile = tokens.nextToken();
String vaknaamInFile = tokens.nextToken();
String resultInFile = tokens.nextToken();
double res = Double.parseDouble(resultInFile);

if((vaknaamInFile.equals("JAVA1")) && (res >= 5.5))
{
studvak1=studvak1 += nameInFile +nl;
}

if((vaknaamInFile.equals("JAVA2")) && (res >= 5.5))
{
studvak2=studvak2 += nameInFile + nl;
}

file = bufferedReader.readLine();
}
JOptionPane.showMessageDialog(null, "Wie Java 1 heeft gehaald:" +"\n"+studvak1 +"\n"+ "Wie Java 2 heeft gehaald:" +"\n"+studvak2 );

bufferedReader.close();

}
else
JOptionPane.showMessageDialog(null,"Geen");

}
catch (Exception ae)
{
JOptionPane.showMessageDialog(null,"Error");



}

}}} }