1 Reply Latest reply on Feb 2, 2012 8:49 AM by PierreSolutions

    dropdownlist selecteditem when using httpservice

    senorhughes

      Hi

       

      I'm new to flex. I have a dropdownlist that I a populating from an httpservice. I'm trying to get the value of the item selected by the user.

       

      ddl.selecteditem.toString() does not seem to work as it returns an object. What is the correct syntax?

       

      The code for my dropdown list is below

       

       

      <!-- xml service for species list -->

              <s:HTTPService id="speciesService"

                             url="http://somexml.xml"/>

       

       

      <s:DropDownList id="ddl"

                                          dataProvider="{speciesService.lastResult.madagascar_species.species}"

                                          labelField = "BINOMIAL"

                                          width="150"/>