Thank you very much for the hep Fou-Lu. I was able to get my program fully working. The only small problem I have left is when I delete an event, the most recent activity is deleted rather than what i specified. This is the code I am using:
Code:
public void deleteEvent() {
Scanner input = new Scanner(System.in);
OurDate date = new OurDate();
OurTime time = new OurTime();
date.inputFromKeyboard();
time.inputFromKeyboard();
for (int i = 1; i <= numEvents; i++) {
Event e = this.activities[i];
if (e.getDate().isEqual(activities[numEvents].getDate()) && e.getTime().isEqual(activities[numEvents].getTime())) {
activities[i] = null;
numEvents--;
activities[i] = new Event();
}
}
}
I have to do this without an array list as well.