10 Replies Latest reply on May 17, 2011 1:05 AM by TheGarfunkal

    listen for a change in a control made by another control programmatically

    TheGarfunkal Level 1



      I have a combobox (A) with a listener for a user change.  I have a second similar combobox(B).


      I want to have a listener that fires on A when B has some interaction.


      So for example - if B is changed, I want the selectedIndex on A to change, and an event on A to fire picking up the Selected Item associated with that Index, but I'm having trouble finding an event that is based on the change.


      Currently the selected index is set by a bindable int in a modelLocator (Im trying to stay true to cairngorm!)  I thought I may have found it with ValueCommit but no luck.  I'm able to change the SelectedIndex on A via the bound variable, and I know i could do something similar on the selectedItem, but I want to work out if its simple to fire an event from within the Combobox of (A)


      I know its hard to picture with no code - but any ideas? - since I've started trying to use cairngorms concepts I seem to hit this problem pretty frequently.  Usually all the code would be in the same place and i could access them via the Ids, but as they are in difference AS files its not as straightforward.


      cheers for any help