User Guide
872 Chapter 6: Components Dictionary
Example
The following example defines a function sendFunction for the send event and assigns the
function to the
addEventListener event handler:
var sendFunction = function (sendEnv) {
sendEnv.target.params = [newParam_txt.text];
};
wsc.addEventListener("send", sendFunction);
WebServiceConnector.status
Availability
Flash Player 6 (6.0 79.0).
Edition
Flash MX Professional 2004.
Usage
componentInstance.addEventListener("status", myListenerObject)
Description
Event; broadcast when a call to a web service 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 condition that occurred
• data: an object whose contents depend on the code
The following are the codes and associated data available for the
status event:
Code Data Description
StatusChange {callsInProgress:nnn} This event is emitted whenever a web service call
starts or finishes. The item nnn gives the number
of calls currently in progress.
CallAlreadyInProgress No data This event is emitted if
trigger() is called,
multipleSimultaneousAllowed is false, and a call
is already in progress. After this event occurs, the
attempted call is considered complete, and there
is no
result or send event.
InvalidParams No data This event is emitted if the
trigger() method
found that the
params property did not contain
valid data. If the
suppressInvalidCalls property is
true, the attempted call is considered complete,
and there is no
result or send event.