public static void importData() {
		
		student = new ArrayList<Student>();

		String csvFile = "src/student.csv";
		// importDialog();
		if (csvFile != null) {
			BufferedReader br = null;
			String line = "";
			String cvsSplitBy = ",";

			try {

				br = new BufferedReader(new FileReader(csvFile));
				while ((line = br.readLine()) != null) {

					// use comma as separator
					String[] user = line.split(cvsSplitBy);
					s = new Student(user[0], user[1], user[2], user[3]);

					// c = new Course(user[4],user[5],user[6]);
					ArrayList<Grades> g = new ArrayList<Grades>();
					g.add(new Grades(user[4].charAt(0)));
					g.add(new Grades(user[5].charAt(0)));
					g.add(new Grades(user[6].charAt(0)));
					g.add(new Grades(user[7].charAt(0)));

					s.setGrades(g);

					student.add(s);
				}
				while ((line = br.readLine()) != null) {

					// use comma as separator
					String[] user = line.split(cvsSplitBy);
					for (int i = 0; i < student.size(); i++) {
						c = new Course(user[4], user[5], user[6]);
						student.get(i).getCourse().add(c);
					}
				}
			} catch (FileNotFoundException e) {
				e.printStackTrace();
			} catch (IOException e) {
				e.printStackTrace();
			} finally {
				if (br != null) {
					try {
						br.close();
					} catch (IOException e) {
						e.printStackTrace();
					}
				}
			}
//			System.out.println("Name" + "		Matric" + "		Age" + "		Gender"
//					+ "	AP3" + "	ALG3" + "	PSD" + "	IS");
//			for (int i = 1; i < student.size(); i++) {
//
//				System.out.print(student.get(i).getName() + "		");
//				System.out.print(student.get(i).getMatric() + "		");
//				System.out.print(student.get(i).getGender() + "		");
//				System.out.print(student.get(i).getAge() + "	");
//
//				alJ = student.get(i).getGrades();
//
//				for (int j = 0; j < alJ.size(); j++) {
//					System.out.print(alJ.get(j).getgrade() + "	");
//				}
//
//				System.out.println("");
//			}

		}

	}