Home > Flash, Flex, FMS > Calling Web Service From FMS

Calling Web Service From FMS

 First step is to load Web Service class . That you can do by:

load(“webservices/WebServices.asc”);

Others steps are same as Web Service call from client side…

  1. Will have to define an WebService

webServiceObj = new WebService(WSDLPath);

where WSDLPath is Web Service WSDL path.

  1. Next we have to define onLoad and onFault methods for the ‘webServiceObj’

webServiceObj.onLoad = function(Wsdl){

trace(“result string — ” + Wsdl);

}

webServiceObj.onFault = function(fault){

trace(“wetherservice fault –” + fault.faultstring);

}

  1. Next step is to call Web Methods…

It’s very much same as

                    callWebMethod = webServiceObj.webMethodName()

                  callWebMethod.onResult = function(returning){

trace( “callWebMethod returning String — “ + returning)

    }

  1. February 24, 2010 at 2:07 PM

    I am happy I found your website on myspace. Thanks for the sensible critique. Me and my neighbour were just preparing to do some research about this. I am glad to see such good information being shared for free out there.
    Best wishes,
    Douglas from Overland Park city

  1. No trackbacks yet.

Leave a comment