Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Binding NSPopupButton [SOLVED]



> I'm having a little problem binding an NSPopupButton to an NSArrayController.
> The problem is that when I first click the popup, I see an extra item at the
> bottom called "No Value". If I choose one of the other items, then the next
> time I click the popup, the "No Value" is gone and everything is good. Does
> anyone understand why the "No Value" item ever gets put into the menu?

I solved this after doing some more thinking. The problem was that I had
bound the NSArrayController's "selectedObject" to an attribute
("selectedConversation") in my model, but I was not setting that attribute.
The solution was to call SetSelectedConversation: after adding the very
first conversation object to the array.

--
Larry Gerndt
AIM Handle: SonOfTheSonOfMan
Let the truth be told though the heavens fall -- James Garrison

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/email@hidden

This email sent to email@hidden

References: 
 >Binding NSPopupButton (From: Larry Gerndt <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.