Please help me extend my understanding of bindings...I grasp the simple stuff, but not yet to an extent to be able to apply that to complex situations.

In my main window (which resides in it's own nib, and is controlled by a custom window controller), I have a combobox. I'd like to populate the contents of that via bindings.

In my main nib file is where the controller lives that maintains the information that I want to populate that combobox with. This controller has a dictionary ("infoDictionary"), and the keys of that dictionary are what I want displayed in the combobox.

My main window class has a member variable (I'm calling this "infoController") that is a link to that information controller. So, I attempted to set up the binding on the combobox as:

Bind to: File's Owner (which is my custom window controller)
Model Key Path: infoController.infoDictionary.allKeys

Truth be told, I didn't really expect that work (and I wasn't disappointed), but I'm really clueless as to what *should* work.

As another stab in the dark, when I set the contents of that dictionary, I tried wrapping that code around calls to:

[self willChangeValueForKey:@"infoController.infoDictionary.allKeys"];
<populate the dictionary here>
[self didChangeValueForKey:@"infoController.infoDictionary.allKeys"];

and that likewise didn't work; the combobox remains empty. (I also tried throwing a "self." at the beginning of the Model Key Path to no avail.)

I also get no output in my debugger console that might lead me to a clue as to what I'm doing wrong.

Help, please?  Thanks!
randy
_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to