• 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
Re: Standard User Defaults - Setting initial values
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Standard User Defaults - Setting initial values


  • Subject: Re: Standard User Defaults - Setting initial values
  • From: Scott Anguish <email@hidden>
  • Date: Mon, 26 Apr 2004 19:49:32 -0400

On Apr 26, 2004, at 7:46 PM, Bruce Truax wrote:

On 4/26/04 7:09 PM, "Scott Anguish" <email@hidden> eloquently wrote:

3. You never need to set the initialValues: unless you're going to
support resetting to the factory defaults.

If I don't set the defaults then the text edit fields come up blank which
can cause and error in the application if the user just hits OK. The Pop up
menus and radio buttons are fine, they retain the settings from interface
builder but for some reason the edit boxes do not. In my application I would
like the edit boxes to contain a valid default value.

Right..

if you set the registerDefaults: and bind those text fields to the appropriate key in the Shared User Defaults controller, it'll look in the values set in registerDefaults: for those values.

It only falls back to the initialValues: if it can't find a value in registerDefaults: and you should have on there. And since you do, you shouldn't have to worry about it.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • SOLVED Standard User Defaults - Setting initial values
      • From: Bruce Truax <email@hidden>
    • Re: Standard User Defaults - Setting initial values
      • From: Bruce Truax <email@hidden>
References: 
 >Re: Standard User Defaults - Setting initial values (From: Bruce Truax <email@hidden>)

  • Prev by Date: Re: KeyValue Observing rant
  • Next by Date: Re: Getting NSFontPanel color changes [SOLVED]
  • Previous by thread: Re: Standard User Defaults - Setting initial values
  • Next by thread: Re: Standard User Defaults - Setting initial values
  • Index(es):
    • Date
    • Thread