This is my first stab at persistent data. It seems the data was saved (as it is supposed to automatically load the data into the view when it opens). now when I add the view I get the crash EXC_BAD_ACCESS (code=2, address=0x7...)
here is the function
- (NSString *) dataFilePath
{
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
NSString *documentsDirectory = [paths objectAtIndex:0];
return [documentsDirectory stringByAppendingPathComponent:@"data.archive"];
}
Here is the line with the crash
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
any ideas on what the problem is?