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

macromedia flash flash remoting

group:

FR too fast for it's own good?



FR too fast for it's own good? Fowie
2/24/2005 3:58:21 PM
macromedia flash flash remoting: I'm using FR with AMFPHP (so maybe that's the only problem?) and I've run into
a problem in that if I try to make two calls to the same service, one after
another, I get an error instead of two result sets. The same two calls work
fine if I leave about 5 frames of nothing in between so they are spaced out
enough to process fully. Is there some sort of command to make flash wait for
the result function to finish before calling the service again so as to avoid
errors?
Re: FR too fast for it's own good? maliko50
2/24/2005 10:52:17 PM
I'm not sure if there is a actionscript command to pause execution for a while
(there probably is) but what I do is call the second service in the first
call's functionName_Result function. That way you know the first call is
complete.
Re: FR too fast for it's own good? Fowie
2/25/2005 3:55:00 PM
I've thought about doing that, but that would be an abnormal situation for my
function, which gets called quite often and I only want it to run once. This
problem happens because when my SWF first loads I have to do a few service
calls to set everything up, so doing that would require a totally new service
and result function declaration or something to that effect, any other ideas?
Re: FR too fast for it's own good? Stephen Beattie
3/2/2005 8:45:28 PM
you could pass, as an additional argument to your remote service method, a
parameter for a callback function ( sent as a string), then send it back
from the server to use in the _Result handler. This way you could
configure any kind of behaviour from the response.

Stephen


[quoted text, click to view]

AddThis Social Bookmark Button