all groups > flash actionscript > may 2006 >
You're in the

flash actionscript

group:

Connecting to the flash remoting gateway not working



Connecting to the flash remoting gateway not working sampurtill
5/18/2006 11:28:24 PM
flash actionscript: Here is my code, I copied it straight out of the flash remoting book...

stop();
import mx.remoting.NetServices
var conn = NetServices.createGatewayConnection("<a target=_blank
class=ftalternatingbarlinklarge href="http://flist.net/flashservices/gateway");
var">http://flist.net/flashservices/gateway");
var</a> testService = conn.getService("net.flist.images.UploadImage", this);
testService.fakeReturn();
function onResult(returnVar){
trace(returnVar);
}

Every time when I'm using it online, it gives me an error saying

Error opening URL "<a target=_blank class=ftalternatingbarlinklarge
href="http://flist.net/flashservices/gateway"

Any">http://flist.net/flashservices/gateway"

Any</a> help? It was working a few weeks ago, so I have no idea why it would
just stop working for me. Thanks,

Sam
Re: Connecting to the flash remoting gateway not working Sankalan
5/19/2006 12:00:00 AM
Hello Sam,

I think what you have done is right. It was working previously, so I guess
there is some settings problem.

Let's give a try with this one :

#include "NetServices.as"

NetServices.setDefaultGatewayUrl("<a target=_blank
class=ftalternatingbarlinklarge href="http://flist.net/flashservices/gateway");
gatewayConnnection">http://flist.net/flashservices/gateway");
gatewayConnnection</a> = NetServices.createGatewayConnection();
defaultService = "net.flist.images.UploadImage";
yourRemotingObject = gatewayConnnection.getService(defaultService, eval(this));

Thanks

Sankalan
( www.mindfiresolutions.com )
AddThis Social Bookmark Button