• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
NSUserDefaults not resetting....
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSUserDefaults not resetting....


  • Subject: NSUserDefaults not resetting....
  • From: Aaron Wallis <email@hidden>
  • Date: Tue, 13 Sep 2005 23:10:18 +1000

Hey all...

Just a quick question about the NSUserDefaults object.

I have a UserDefault variable which is a singleton set in the header:

    NSUserDefaults * preferenceData;

Now, when I try to reset the preferences [ through a button on the interface ] using the following code:

    - ( void ) resetPreferences
    {
        NSLog(@"reset preferences - this is not working !!!");
        [ preferenceData resetStandardUserDefaults ];

        [ self setDefaultPreferences ];
    }

Where setDefaultPreferences is a method that sets up the default prefs.

This code is returning the error:
NSUserDefaults may not respond to -resetStandardUserDefaults?

Any idea what im doing wrong?
I would have thought this would have worked scenes its in the documentation!?


Cheers
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: NSUserDefaults not resetting....
      • From: Craig Phillips <email@hidden>
  • Prev by Date: Re: Manual bindings without key path?
  • Next by Date: Re: Why NSWindowController for non-document windows?
  • Previous by thread: Re: Manual bindings without key path?
  • Next by thread: Re: NSUserDefaults not resetting....
  • Index(es):
    • Date
    • Thread