Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Chirone

macrumors 6502
Original poster
Mar 2, 2009
279
0
NZ
there seems to be quite a few things about binding some contents of an array controller to a pop up button, but i can't seem to see anything on how to bind the array contents of an entity to a popup button..

in this case, EntityOne has an id attribute, which is supposed to be an NSMutableArray of NSStrings

in the popup button's bindings i binded the content to EntityOne with controller key arrangedObjects
with Modal Key Path theMutableArray (theMutableArray being the attribute that is meant to be a mutable array)
i thought maybe that would work seeing as how you'd normally just bind it to the controller with controller key arrangedObjects

that got confusing so i made a new array controller and i think i've binded it's contents to the contents of myMutableArray

so... now, the popup buttons content is binded to myMutableArrayController
with controller key arrangedObjects and a blank Modal Key Path

then with Content Value i got confused
normally you'd bind it to myMutableArrayController with controller key arrangedObjects and Modal Key Path being whatever value you want to display..
umm... NSString doesn't have anything... so i tried length
binded selection index to myMutableArrayController with controller key selectionIndex

and what i got out of it was a dead popup button. nothing was there...

what am i doing wrong? is it because core data doesn't know anything about NSMutableArray and stores the variable as an id?
 
.... turns out i had a typo in awakeFromNib and so everything was broken

although now it displays the value of the array in brackets...
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.