2 Replies Latest reply on Aug 18, 2010 6:11 AM by Flex4Education

    Access a result from a Webservice

    Flex4Education

      Hi!

       

      In Flex 3.5 you could start a Webservice-Request with "webserviceName.functionName();" and via "addfunctionNameEventListener(resultFunction);" you could redirect the result to a specified function. In that function you received the requested values as a event, given by the Webservice-Responde. Through "event.result.data.id" you could select the values inside the event. Now, Flash Builder 4 made all this work redundant. With the newly implemented UI-Databinding you can right-click a DataGrid and bind the data directly to it.

       

      As far as I know, you need to assign the result of a Webservice-Call to a UI-Componente in order to display, to access them. Isn't there any other way, to gain access to the sent date in the event and manage the values in "old-school" style, like in 3.5 through "event.result..."? Because I do not want to display certain results. As a work-around I set the unwanted components invisible and copied the values in a local ArrayCollection.

       

      If yes, how can I access them? All I can see at the moment is: "webservicecResult.token = webservices.function();" But there are no specified value in the event nor the datatype, when using the Debug-Mode to view them.

       

       

      Many thanks in advance!

      Flex4Education