ActionScript 2.0 Components Language Reference |
|
|
|
| WebServiceConnector component > WebServiceConnector.WSDLURL | |||
Flash Player 6 (6.0.79.0).
Flash MX Professional 2004.
componentInstance.WSDLURL
Property; the URL of the WSDL file that defines the web service operation. When you set this URL while authoring, the WSDL file is immediately fetched and parsed. The resulting parameters and results appear in the Schema tab of the Component inspector. The service description also appears in the Web Service panel.
This example returns data from a remote web service and traces a tip. Drag a WebServiceConnector component into your library, and enter the following code on Frame 1 of the timeline:
import mx.data.components.WebServiceConnector;
var res:Function = function (evt:Object) {
trace(evt.target.results);
};
var wsConn:WebServiceConnector = new WebServiceConnector();
wsConn.addEventListener("result", res);
wsConn.WSDLURL = "http://www.flash-mx.com/mm/tips/tips.cfc?wsdl";
wsConn.operation = "getTipByProduct";
wsConn.params = ["Flash"];
wsConn.suppressInvalidCalls = true;
wsConn.trigger();
|
|
|
|