all groups > macromedia flash flash remoting > february 2004 >
You're in the

macromedia flash flash remoting

group:

Newbie Question


Newbie Question AviB
2/9/2004 3:37:23 AM
macromedia flash flash remoting:
I just started learning flash remoting, and i downloaded a sample app and it
works fine but i can't figure out how to pass a variable through flash to the
cfc and then have the cfc do a query and pass back the results, can someone
please help me figure this out, any help is very much appreciated

============================Actionscript
Code===================================

#include "NetServices.as
#include "NetDebug.as

function Result(

//receives data returned from the metho
this.onResult = function(result

trace("Data received from server : " + result)
//this is where we put the data in the text field
dataField.text = "Data received from server : " + result


this.onStatus = function(error

trace("Error : " + error.description)
//this is where we put the data in the text field
dataField.text = "Error : " + error.description



NetServices.setDefaultGatewayUrl("http://localhost/flashservices/gateway")
var gw = NetServices.createGatewayConnection()
var server = gw.getService("sources.HelloWorld", new Result())
server.sayHello()
=================================End of Code===================================
Re: Newbie Question AviB
2/9/2004 3:54:31 AM
AddThis Social Bookmark Button