开发者

How to handle SOAP response in FLEX 3


SOAP Request
<?xml version="1.0" encoding="UTF-8"?>

<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">

<S:Header/>

<S:Body>

<ns2:deleteDataView xmlns:ns2="http://ws.$$$$$.@@@@@.####.com/">

<identifier>5</identifier> </ns2:deleteDataView>

&lt;/S:Body&gt;

</S:Envelope>


SOAP Response
<?xml version="1.0" encoding="UTF-8"?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Body>

<ns2:deleteDataViewResponse xmlns:ns2="http://ws.$$$$$.@@@@@.####.com/">

<return>ERROR: A bug has been encountered,please try later</return&gt

</ns2:deleteDataViewResponse> </S:Body> </S:Envelope>


I want to read SOAP response in flex,am some what n开发者_开发技巧ew to FLEX,pls help,even good resources will work.


Handling SOAP Response

<mx:WebService
      id="userRequest"
       wsdl="http://www.gnpcb.org/esv/share/soap/index.php?wsdl">

       <mx:operation name="doPassageQuery" resultFormat="object"
            fault="mx.controls.Alert.show(event.fault.faultString)"
            result="showResult(event)"/>
 </mx:WebService>

In the above code you are accessing your SOAP WebService, now you have the resultFormat is an Object and the result function is showResult()

  private function showResult(e:ResultEvent):void 
   {
   trace(e.result);
   }

Resources

http://www.flexlive.net/?p=79

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜