Okay, so ultimately I want a program where the user can input simple data such as their name, date of birth, address, etc. and then have that information stay through multiple views. I am having the user input their information as UITextFields but their are multiple views that they are using to input the data. Is there a way that when the user inputs data in a UITextField - then moves to another view - then returns to the original view - that the data will still be in that UITextField? I figure since there are placeholders that there must be a command to show previously written text in that field when the viewController is called.
Also, for the life of me, I can't figure out how to keep these variables global. I have read in multiple areas that I should define them in the AppDelegate as a simple:
NSString *userName;
NSString *userDOB;
But how do I assign the strings from the UITextFields in a different view to these variables and then re-assign them to the UITextFields when the user returns to the place where they originally input them?
(I apologize if I am not explaining this coherently - I am a bit of a newb)
-EDIT- I have followed the link below but still can't figure this out. I tried using:
NSString *name = [[NSUserDefaults standardUserDefaults]objectForKey:@"name"];
[[NSUserDefaults standardUserDefaults]setObject:@"Horace" forKey:@"name"];
but I must not be using them in the correct place. Where would i use this commands? If I am having the user input the variables in say "ViewController1" - should I put these commands somewhere in the "ViewController1.m" file? For the life of me I can't figure this out.