views:

47

answers:

2

I'm trying to develop a basic GPA Calculator. I have an AllCourses class that holds Course objects.

I have an AllCourses object in my CalcAppDelegate.

In my ThirdViewController I can successfully update the number of Courses in my AllCourses object. However, the problem I'm having is that when I switch to the RootViewController the UITable isn't being repopulated with the updated Courses that were added.

I tried [self reloadData] in the viewWillAppear in my RootViewController but it caused my app to close. I didn't use IB to create the views so I think it could be the case that I don't have things hooked up correctly. I did it programatically. Does anyone see anything I'm missing in my code?

Here is the link to my project http://files.me.com/aahrens/q0odzi

A: 

have you tried [self.tableView reloadData]

damon
I get an uncaught exception when I do that.
aahrens
A: 

Try

[[self tableView] reloadData]

The method is implemented in UITableView rather than in UITableViewController, which is why your app crashed.

jlehr
I get an uncaught exception when I do that.
aahrens