mutableArrayValueForKeyPath gives me valueForUndefinedKey
mutableArrayValueForKeyPath gives me valueForUndefinedKey
- Subject: mutableArrayValueForKeyPath gives me valueForUndefinedKey
- From: Michael Hanna <email@hidden>
- Date: Fri, 8 Jul 2005 18:42:41 -0400
in my AppController(which is the outlet of an NSController via IB) I
have a field instance
NSMutableArray *entries;
which is observed with an Entries NSArrayController such that
contentArray:
Bind To: DLControllerAlias(NSController)
Controller Key: selection
Model Key Path: entries
It contains DLEntry objects. Each DLEntry has another NSMutableArray
called passages(which is also observed with an NSArrayController
Passages):
contentArray:
Bind To: Entries
Controller Key: selection
Model Key Path: passages
of DLPassage objects
when I try to add a single DLPassage object to a given DLEntry:
if ([oEntriesTable selectedRow] == -1)
return;
NSMutableArray * passagesArray;
NSMutableArray * entriesArray = [self mutableArrayValueForKey:
@"entries"];
DLEntry *anEntry = [entriesArray objectAtIndex:[oEntriesTable
selectedRow]];
passagesArray = [self mutableArrayValueForKeyPath:
@"anEntry.passages"];
this results in an error:
2005-07-08 18:29:46.469 DreamLog[19937] [<DLController 0x363090>
valueForUndefinedKey:]: this class is not key value coding-compliant
for the key anEntry.
looked into this by searching the archives but came up with nothing
on mutableArrayValueForKeyPath. Any ideas why this is happening? I'm
quite the newb on all things bindings.
regards,
Michael
_______________________________________________
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