• 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: DOESN'T RESTORE PREFS UNLESS APP IS QUIT.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: DOESN'T RESTORE PREFS UNLESS APP IS QUIT.


  • Subject: Re: DOESN'T RESTORE PREFS UNLESS APP IS QUIT.
  • From: Stéphane Sudre <email@hidden>
  • Date: Wed, 4 Feb 2004 17:55:16 +0100

On mercredi, fivrier 4, 2004, at 04:43 PM, email@hidden wrote:

I have the following routine that is exicuted when the "Apply" button is
pressed.
_______________________________________________

- (IBAction)savePrefs:(id)sender
{
[[NSUserDefaults standardUserDefaults] setObject:[myPopUp
titleOfSelectedItem] forKey:@"Active Device"];
[[NSUserDefaults standardUserDefaults] setInteger:[allowUSB state] forKey:
@"Allow USB"];
[[NSUserDefaults standardUserDefaults] setInteger:[enableAtStart state]
forKey:@"Enable At Start"];
}

- (IBAction)savePrefs:(id)sender
{
NSUserDefaults * tUserDefaults;

tUserDefaults= [NSUserDefaults standardUserDefaults];

[tUserDefaults setObject:[myPopUp titleOfSelectedItem] forKey:@"Active Device"];
[tUserDefaults setInteger:[allowUSB state] forKey:@"Allow USB"];
[tUserDefaults setInteger:[enableAtStart state] forKey:@"Enable At Start"];

[tUserDefaults synchronize];
}

P.S:

I strongly suggest you to buy a new keyboard. The one you're using has the Caps lock turn on when you type in the Subject: field.
_______________________________________________
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: 
 >DOESN'T RESTORE PREFS UNLESS APP IS QUIT. (From: email@hidden)

  • Prev by Date: Re: Cocoa/Windows parallel dvlpmt
  • Next by Date: Insert two objects under the same column
  • Previous by thread: Re: DOESN'T RESTORE PREFS UNLESS APP IS QUIT.
  • Next by thread: Insert two objects under the same column
  • Index(es):
    • Date
    • Thread