For some reason since last night Xcode just stopped working properly, it doesn’t autocorrect, provide code hints, and doesn’t recognize errors until built. And now I can’t even get my code to work 100% properly.
My objects won’t add to my array.
.h
NSMutableArray *notesTitle;
NSMutableArray *notesBody;
.m
- (void)viewDidLoad
{
[super viewDidLoad];
notesTitle = [[NSMutableArray alloc]init];
notesBody = [[NSMutableArray alloc]init];
}
...
[notesTitle addObject:noteTitle.text];
[notesBody addObject:noteText.text];
///noteTitle.text and noteText.text do contain Text
And Both Array’s turn out as null
Unrelated; try removing your derived data directory entirely and rebuilding.
Are you sure your
viewDidLoadmethod has been invoked? Set a breakpoint (or print something out).