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></S:Body>
</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> </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
精彩评论