I am quite new to java and I'm trying to create student record system.
At the moment I'm storing my "registered student" in an ArrayList of Objects.
I would like to be able to modify the value of for e.g. the first name of a specific student. The ID of the student is also his position in the ArrayList.
Here is how I tried to do it but it doesnt seem to work:
StudentStoring.StudentList.get(id)
.setTitle(comboTitle.getSelectedItem().toString());
This is the bit of code that is suppose to take the new value of the title in the modifying page and replace the old one but I get an IndexOutOfBound error.
Thanks.
idis beyond the length of the array. Keep in mind that the first index is 0 (not 1).