• 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
Ghost value in NSUserDefaults
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Ghost value in NSUserDefaults


  • Subject: Ghost value in NSUserDefaults
  • From: Stephan Burlot <email@hidden>
  • Date: Sun, 9 Jan 2005 14:47:29 +0100

Hi,

I have a value in my NSUserDefaults which seems to come from nowhere:

I have in my project's info.plist:
	<key>CFBundleIdentifier</key>
	<string>com.colorplaza.colormailer</string>

I do a rm ~/Library/Preferences/com.colorplaza.colormailer.plist
(just to be sure, doint a defaults read com.colorplaza.colormailer
gives:
2005-01-09 14:28:31.932 defaults[22987]
Domain com.colorplaza.colormailer does not exist
)

I start my application and do:
#define COUNTRY_KEY	@"Country"

NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults];
NSDictionary *defaultValues = [NSDictionary dictionaryWithObjectsAndKeys:
@"", SERVICE_KEY,
@"", COUNTRY_KEY,
@"", LANGUAGE_KEY,
@"", USERNAME_KEY,
@"", PASSWORD_KEY,
nil, ALERT_KEY,
@"No", MODE_KEY,
@"", DEFAULT_PAPERID_KEY,
@"", SERVICE_ID_FOR_PAPER_KEY,
nil];


	[userDefaults registerDefaults:defaultValues];

NSLog(@"country: %@", [[NSUserDefaults standardUserDefaults] objectForKey:COUNTRY_KEY]);

and I get:
country: CH

Where does this value comes from?

Thanks for any help,
Stephan

_______________________________________________
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: Ghost value in NSUserDefaults
      • From: Kevin Ballard <email@hidden>
    • Re: Ghost value in NSUserDefaults
      • From: Clark Cox <email@hidden>
  • Prev by Date: [basics] saving UntitledFile without panel
  • Next by Date: Implementing Object persistence
  • Previous by thread: [basics] saving UntitledFile without panel
  • Next by thread: Re: Ghost value in NSUserDefaults
  • Index(es):
    • Date
    • Thread