• 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
NSPopUpButton - addItemsWithTitles
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSPopUpButton - addItemsWithTitles


  • Subject: NSPopUpButton - addItemsWithTitles
  • From: "Derek Chung" <email@hidden>
  • Date: Thu, 14 Sep 2006 11:37:37 -0700

I have set an NSPopUpButton with an array of strings like below:

myArray = [NSArray arrayWithObjects:@"a", @"b", @"c", @"d", nil];
myOtherArray = [NSArray arrayWithObjects:@"e", @"f", @"g", nil];
[myPopUp removeAllItems];
[myPopUp addItemsWithTitles:myArray];

Can I simply remove all Items in the NSPopUpButton and repopulate items with
another array like below?

[myPopUp removeAllItems];
[myPopUp addItemsWithTitles:myOtherArray];

Thanks for your help in advance.

- dnwood
_______________________________________________
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: NSPopUpButton - addItemsWithTitles
      • From: "I. Savant" <email@hidden>
  • Prev by Date: Re: NSOutlineView variable width cell
  • Next by Date: determine if Dashboard is active...
  • Previous by thread: Re: NSOutlineView variable width cell
  • Next by thread: Re: NSPopUpButton - addItemsWithTitles
  • Index(es):
    • Date
    • Thread