ActionScript 2.0 Components Language Reference |
|
|
|
| XMLConnector component > XMLConnector.status | |||
Flash Player 6 (6.0.79.0).
Flash MX Professional 2004.
componentInstance.addEventListener("status",myListenerObject)
Event; broadcast when a remote procedure call is initiated, to inform the user of the status of the operation.
The parameter to the event handler is an object with the following fields:
type: the string "status"target: a reference to the object that emitted the event (for example, a WebServiceConnector component)code: a string giving the name of the specific condition that occurreddata: an object whose contents depend on the codeThe code field for the status event is set to Fault if problems occur with the call, as follows:
|
Code |
Data |
Description |
|---|---|---|
|
Fault |
{faultcode: code, faultstring: string, detail: detail, element: element, faultactor: actor} |
This event is emitted if other problems occur during the processing of the call. The data is a SOAPFault object. After this event occurs, the attempted call is considered complete, and there is no |
The following are the faults that can occur with the status event:
|
FaultCode |
FaultString |
Notes |
|---|---|---|
XMLConnector.Not.XML
|
params is not an XML object |
The |
XMLConnector.Parse.Error
|
params had XML parsing error NN. |
The |
XMLConnector.No.Data.Received
|
no data was received from the server |
Due to various browser limitations, this message can mean either (a) the server URL was invalid, did not respond, or returned an HTTP error code; or (b) the server request succeeded but the response was 0 bytes of data. To work around this restriction, design your application so that the server never returns 0 bytes of data. If you receive the fault code |
XMLConnector.Results.Parse.Error
|
received data had an XML parsing error NN |
The received XML was not valid, as determined by the Flash Player built-in XML parser. To see the possible errors NN, see |
XMLConnector.Params.Missing
|
Direction is 'send' or 'send/receive', but params are null. |
The following example defines a function statusFunction for the status event and assigns the function to the addEventListener event handler:
var statusFunction = function (stat) {
trace(stat.code);
trace(stat.data.faultcode);
trace(stat.data.faultstring);
};
xcon.addEventListener("status", statusFunction);
|
|
|
|