2 Replies Latest reply on Apr 16, 2010 2:42 PM by SpaghettiCoder

    FB 4 - how to bind DropDown to state




      I have been looking through the knowledge base and can't seem to come up with the answer I am looking for.


      I want, when an item is selected from a dropdownList control, for it to go to that certain state. I have currently 12 states, of which 11 will be accessible from the dropdown. The dropdownlist is being populated from a WebService.


      I am sure its pretty easy, but can't figure out how to do it!





        • 1. Re: FB 4 - how to bind DropDown to state
          ThiaKPSU Level 1

          OK - my issue seems to be coming up with the value of the DropDown.SelectedItem.


          I have tried dozens of script ideas, but so far, all I keep getting are errors.


          in my latest attempt, I have currentState = '{dropDownListServices.SelectedItem.state}'; I tried appending a .text onto state, but it is a no go as well.


          state is one fo the items from the xml resource that the dropDownList references.


          What am I doing wrong>?



          • 2. Re: FB 4 - how to bind DropDown to state
            SpaghettiCoder Level 3

            //Add this to your combo box



            private function changeHandler():void




                      case "whatever1" :

                           currentState = 'stateName1';



                      case "whatever2" :