Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

jerrywickey

macrumors member
Original poster
Apr 16, 2009
81
0
Key West
In this app, I have a lot of user data that will be saved for the next time the pp is launched.

Is

[aString writeToFile: filename]

and

aString = [NSString stringWithContentsOfFile: filename]

the easiest way to save data?

In the simulator file filename ends up in the hard-drive's root directory. Where does it end up in the iPhone?

Does it matter where it ends up because the iPhone's "harddrive" can't actually be accessed by the user?

Where should I put the file?

Is there a function that returns a file path that is specific to the app?

Jerry
 

Jeremy1026

macrumors 68020
Nov 3, 2007
2,215
1,029
In this app, I have a lot of user data that will be saved for the next time the pp is launched.

Is

[aString writeToFile: filename]

and

aString = [NSString stringWithContentsOfFile: filename]

the easiest way to save data?

In the simulator file filename ends up in the hard-drive's root directory. Where does it end up in the iPhone?

Does it matter where it ends up because the iPhone's "harddrive" can't actually be accessed by the user?

Where should I put the file?

Is there a function that returns a file path that is specific to the app?

Jerry

You'll first need to create a file path to your apps Document directory.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.