I have a Flash interface that periodically calls the server to get updated information. The call uses the flex class sdk rpc.soap.Operation. It looks something like this:
var wsOperation:Operation = Operation(webService.getOperation(SomeOperation));
wsOperation.addEventListener("fault", wsError);
wsOperation.addEventListener("result", wsResult);
wsOperation.send(...some params);
This call retrieves some data from an SQL database. I programmed the call right before sending it to the beginning of the wsResult function in ~ 4 seconds. During this time, my user interface is not updated. He is frozen / not responding.
Now I know that Flash is single-threaded / asynchronous, so I'm not sure why this is happening. I see that the send (..) function returns an AsyncToken, which I do not use. Could this have anything to do with this?
Any other ideas as to why this is happening are appreciated. Thank.
I still have not found an acceptable solution. It seems ridiculous that I would have to use Pseudo thread to get flash to update the user interface during a 4 second call. I am wondering, maybe parsing a syntax response can take a lot of time. If a lot of processing is required, will the time delay update the UI indefinitely?
source
share