binding to arraycollection does not work
Posted
by ron
on Stack Overflow
See other posts from Stack Overflow
or by ron
Published on 2010-05-23T14:34:57Z
Indexed on
2010/05/23
14:40 UTC
Read the original article
Hit count: 296
Hi,
I am using flex SDK 3.5. I have model.as and in it i have an ArrayCollection (name it arr_mod) which is Bindable.
From my mxml i link to this arr_mod in two ways:
1) in DataGrid i set dataprovider={arr_mode} ...
2) in Button i add new item to the arr_mod this way:
3) in textBox i want to add mx:TextBox text="{mySpecialCounterFunc(arr_mod)}"
note that in the Script of mxml arr_mod is Bindable as well as in the class definition in model.as
The problem is, that when clicking on button, mySpecialCounterFunc is not called! it should be called, since i use {} and this should listen to changes in arr_mod (a change that was made in the button should cause a new item to be added.. and than the listener to respond).
While The DataGrid is updated correctly!
Why??
© Stack Overflow or respective owner