Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsGeneralPHPASPPerlColdFusionFlashHTML, CSS, ScriptsBrowsers

Webmaster Forum / Flash / Flash Remoting / June 2005



Tip: Looking for answers? Try searching our database.

Help : Using the RelayResponder

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
lewisw5 - 29 Jun 2005 03:50 GMT
import mx.remoting.Service;
import mx.rpc.RelayResponder;
import mx.remoting.PendingCall;
import mx.rpc.ResultEvent;
import mx.rpc.FaultEvent;
import mx.services.Log;

function getString_Result(evt:ResultEvent):Void {
        responseAreaText.text = evt.result;
}

function getString_Fault(evt:FaultEvent):Void {
        trace("Error: "+evt.fault.__faultstring);
        responseAreaText.text = fault.fault.faultstring;
}

requestButton.clickHandler = function() {
        var service:Service = new Service(gatewayPath.text, new Log(),
"hello", null,null);
        var mypc:PendingCall = service.getString();
        mypc.responder = new RelayResponder(this, "getString_Result",
"getString_Fault");
}

The function getString_Result and getString_Fault never be invoked. Why?
ufitzi - 29 Jun 2005 18:38 GMT
do a trace(this) inside of clickHandler().
It may be referencing the wrong object.
If requestButton is actually a MovieCLip, "this" is referencing the MC and the
functions _Result and _Fault will not be found.
good luck
bh
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.