Reputation: 251
I am new to FLEX and I want to invoke a service that returns a string object:
<mx:WebService id = "myService" wsdl = "http://myhost.com/Service1.svc?wsdl">
<mx:operation name = "opName" resultFormat = "object" />
</mx:WebService>
What is the syntax to store the string returned by the service in a variable?
Upvotes: 0
Views: 106
Reputation: 3914
Simple, use the result
handler:
<mx:WebService ... result="myResultHandler(event)">
public function myResultHandler(e:ResultEvent):void {
myVar = e.result;
}
See also see: reference1 and reference2
Upvotes: 1