I'd rather not use a labelFunction, instead just using a labelField
would be fine.
So I tried adding a different array of objects, and it works. So it
has something to do with either the array of objects I want to pass,
or the objects inside of that array.
The array consists of Node objects, which are AS versions of some
remote POJOs that I get a set of.
They don't contain much; just an id field and some relational
information. Here's the entire AS class:
import pojos.*;
class pojos.Node {
public static var regClass = Object.registerClass("pojos.Node",
pojos.Node);
public var id:String, name:String, groupID:String;
public var nodeType:NodeType;
public var group:Group;
public var organization:Organization;
public function Node() {}
public function get data() {
return this;
}
public function get label() {
return id;
}
}
Thanks! -Josh
--- In [email protected], "Tracy Spratt" <[EMAIL PROTECTED]>
wrote:
> If your dataProvider has data then look again at your labelField
> settings or labelFunction code.
>
> In a labelFunction, be sure to use the dataProvider API methods, not
> array or xml methods. Use a trace in the labelFunction, or step
through
> it in the debugger, you should be able to see what is happening.
>
> What does your array contain? Indexed Arrays or Objects?
>
> Post a sample of the data and the labelFunction.
>
> Tracy
>
> -----Original Message-----
> From: [email protected] [mailto:flexcod
[EMAIL PROTECTED] On
> Behalf Of cazzaran
> Sent: Wednesday, June 08, 2005 6:32 PM
> To: [email protected]
> Subject: [flexcoders] Trouble getting mx:List to show any changes to
> dataProvider
>
> For some reason, I have one mx:List in mxml that refuses to show the
> contents of its dataProvider.
>
> I have:
>
> <mx:List height="100%" width="100%" id="theRDUList"
> vScrollPolicy="auto" dragEnabled="false" change="" selectable="true"
> hScrollPolicy="auto"/>
>
> And my code to change it is:
>
> theRDUList.dataProvider = group.nodes;
>
> The thing is, upon debug, I can see that group.nodes is full of an
> Array, *AND* the dataProvider property of theRDUList is ALSO full of
> the same data. So the dataProvider is getting set, but the list
> absolutely refuses to show anything, despite my attempts.
>
> I've tried multiple labelField settings, labelFunc settings, adding
> implicit gets to my Node object (in the Array) so that nothing
should
> be required on the MXML tag... nothing. And all my other lists work
> fine.
>
> Anyone know of something I'm missing? This seems straight forward...
>
> Weird...
>
> -Josh
>
>
>
>
>
>
> Yahoo! Groups Links
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/