Sure!

my list is defined as follows:

               <mx:List id="lstData" width="100%" height="100%"
labelField="@name" ></mx:List>

In my component (well, class) i have the following variable:

       [Bindable]
       public var MyDataList:XMLList = new XMLList();

then when the application loads and i get the instance of the component, i
call the following:
       lstData.dataProvider = mycomponent.MyDataList;

everything looks ok so far, right? then then when i receive a proper xml, i
update it all inside the component:

                       MyDataList = new XML(myxmlstring).children();

theoretically the lstData should somehow receive notification that the
dataProvider has been updated and refresh itself, right? this doesn't seem
to work. Since this doesn't seem to work we're reserved to throwing events
from the component to the list and rebinding the list when that event is
caught by the gui, but the whole thing is pretty cumbersome and i think this
should work automatically.... what are we doing wrong?

Thank you!
On 2/22/07, Igor Costa <[EMAIL PROTECTED]> wrote:

  It would be nice to see your part of you code to see what you are doing
wrong.


Regards.

On 2/22/07, darvon4u < [EMAIL PROTECTED]> wrote:
>
>   Here is an interesting one, not sure if i'm missing something or what.
>
> I have a list to show some data.
>
> I also have a component with an xmllist property which is marked as
> [Bindable]
>
> in actionscript, i instantiate that component and bind this data
> property to the list.
>
> When i receive data from webservice, i update the xmllist of the
> component. shouldn't the visual list update as well since it is bound
> to that component's property?
>
> also, i have tried this with an XMLListCollection as well and same
> result. only if i rebind the list to the component's property do i get
> the result.
>
> what i am doing wrong? is this by design? should there be something
> else wired or triggered for the updates to occur automatically?
>
> thank you in advance if anybody can help in any way,
>
> -A
>
>


--
----------------------------
Igor Costa
www.igorcosta.org
www.igorcosta.com
skype: igorpcosta

Reply via email to