Re: Classcastexception _EOCheapMutableArray Solved
Re: Classcastexception _EOCheapMutableArray Solved
- Subject: Re: Classcastexception _EOCheapMutableArray Solved
- From: Lachlan Deck <email@hidden>
- Date: Mon, 10 Dec 2007 10:33:23 +1100
On 10/12/2007, at 5:45 AM, Don Lindsay wrote:
When I use the following settings I can save and the listbox shows
the correct number of rows and the correct selected items.
Great.
ToManyRelationship: WOToManyRelationship {
sourceEntityName = "Agents";
destinationDisplayKey = "orgs";
sourceObject = agent;
relationshipKey = "mgtOfc";
}
However it is a cominbation of all fields in the orgs entity that
are being displayed separated by commas and surrounded by curly
braces. So I set destinationDisplayKey to orgs.description
to get a more user friendly view. I get an error that
com.webobjects.foundation.NSKeyValueCoding$UnknownKeyException:
valueForKey(): lookup of unknown key: 'orgs.description'.
You need to set the destination display key as the key *from* the
objects found at "mgt0fc" rather than from your source object.
So that should be something like:
destinationDisplayKey = "org.description"; // i.e., it's a toOne from
your join record.
with regards,
--
Lachlan Deck
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden