• 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: kCFPreferencesAnyUser w/PreferencePane not working?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: kCFPreferencesAnyUser w/PreferencePane not working?


  • Subject: Re: kCFPreferencesAnyUser w/PreferencePane not working?
  • From: Tom Harrington <email@hidden>
  • Date: Tue, 22 Jun 2004 14:24:52 -0600

On Jun 22, 2004, at 1:03 PM, Huyler, Christopher M wrote:
I have a PreferencePane which controls system wide preferences. I tried
the following to store the preferences but it just creates a preferences
file in the current user's ~/Library/Preferences folder instead of a
file in /Library/Preferences. Am I missing something?

tmpString = [worker getAlert];
if (tmpString)
{
[alertField setStringValue:(NSString *)tmpString];
CFPreferencesSetAppValue( CFSTR("alertField"), tmpString, prefID,
kCFPreferencesAnyUser, kCFPreferencesAnyHost);
}
CFPreferencesSychronize( prefID, kCFPreferencesAnyUser,
kCFPreferencesAnyHost );

The current user may not have the appropriate permissions to write to global preferences. I would have expected the error in that case to be a failure to write, but I could be mistaken about that. Also, are you sure you want kCFPreferencesAnyHost rather than kCFPreferencesCurrentHost?

--
Tom Harrington
email@hidden
_______________________________________________
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.


References: 
 >kCFPreferencesAnyUser w/PreferencePane not working? (From: "Huyler, Christopher M" <email@hidden>)

  • Prev by Date: Really Big Windows and Interrupting computations?
  • Next by Date: Re: NSTask Question
  • Previous by thread: kCFPreferencesAnyUser w/PreferencePane not working?
  • Next by thread: RE: kCFPreferencesAnyUser w/PreferencePane not working?
  • Index(es):
    • Date
    • Thread