NSUserDefaults Question

Discussion in 'iOS Programming' started by AndyCodez, Dec 6, 2009.

  1. macrumors regular

    Joined:
    Aug 6, 2009
    #1
    Currently I use NSUserDefaults for in app purchase. Basically stores a bit flag to see whether or not the user has purchased the additional content. This application has not been released yet and I was wondering if the NSUserDefaults are stored when the app is backed up by the user in itunes.

    Lets hope this is backed up when the user makes a back up of their applications.


    Thanks for the help!
     
  2. Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #2
    I believe it is. At least, I used the same solution as you.
     
  3. macrumors 6502

    Joined:
    Oct 31, 2007
    Location:
    San José
    #3
    If you look at "Files and Networking" in the "iPhone Application Programming Guide" Apple tells you which directories are backed up with each sync. The User Defaults should be saved.
     
  4. thread starter macrumors regular

    Joined:
    Aug 6, 2009
    #4
    Thanks guys! I thought so, makes life alot easier.
     
  5. macrumors newbie

    Joined:
    Sep 25, 2008
    #5
    Could you show your code you used to accomplish this, it would be of great help to combat many confusing, unsuccessful, or incomplete references for using NSUserDefaults? Thanks.


     

Share This Page