FROM : Pavel Hlavnicka
DATE : Thu Jun 01 20:01:40 2006
Hi all,
I've problem as follows, looks like a bug, but usually it's not :)
- I have a core data entity with an integer value
- in UI I want to have NSPopuppButton to edit it and display some human
readable value
- to achieve this I have a property file with enumerations (see example)
- in runtime I parse this property file and bind it to
NSObjectController
- for NSPopupButton I set content contentObjects contentValues to array
controller bound to NSObjectController (all to arangedObjects)
- selectedObejct is bound to array controller for the entity (selection)
So far so good... but is stops working as I try to use the same in
NSTableView with colum enhanced with NSPopupButtonCell.
As soon as I do this (and I change selectedObject binding from selection
to arrangedObjects) it sopos to work and I see an excetion telling that
[NSNumber] does not support key-value coding for "value" - what is the
name of non-core data controller used for contentValues binding.
Sample code is available here:
http://termit.gingerall.cz/~pavel/cocoa/coreissue.tar.gz
Current code is broken, just remove "type" column from NSTableView or
unbound it and it works with simple NSPopupButton.
Thanks in avance for any explanation.
P.
--
Pavel Hlavnicka
Ginger Alliance
www.gingerall.com
DATE : Thu Jun 01 20:01:40 2006
Hi all,
I've problem as follows, looks like a bug, but usually it's not :)
- I have a core data entity with an integer value
- in UI I want to have NSPopuppButton to edit it and display some human
readable value
- to achieve this I have a property file with enumerations (see example)
- in runtime I parse this property file and bind it to
NSObjectController
- for NSPopupButton I set content contentObjects contentValues to array
controller bound to NSObjectController (all to arangedObjects)
- selectedObejct is bound to array controller for the entity (selection)
So far so good... but is stops working as I try to use the same in
NSTableView with colum enhanced with NSPopupButtonCell.
As soon as I do this (and I change selectedObject binding from selection
to arrangedObjects) it sopos to work and I see an excetion telling that
[NSNumber] does not support key-value coding for "value" - what is the
name of non-core data controller used for contentValues binding.
Sample code is available here:
http://termit.gingerall.cz/~pavel/cocoa/coreissue.tar.gz
Current code is broken, just remove "type" column from NSTableView or
unbound it and it works with simple NSPopupButton.
Thanks in avance for any explanation.
P.
--
Pavel Hlavnicka
Ginger Alliance
www.gingerall.com
| Related mails | Author | Date |
|---|---|---|
| No related mails found. | ||






Cocoa mail archive

