OK, so I understand that Flex web service calls are asynchronous, and I 
understand the many cases where this makes sense since you don't have 
to hold up the UI experience while waiting for a web service or remote 
procedure to return a result.

However, I keep running into instances where this makes my life hell. 
One example is the submission of an order on a Flex site I have.  
Because of the way the order is handled, it is split into multiple 
(smaller) orders and then each order is submitted/saved via a web 
service call.  This means that one order could have 10+ web service 
calls.  I have a "Print Receipt" button which then uses the saved order 
data to produce a PDF receipt.  The problem is, if a user clicks "Print 
Receipt" before all the save order web services have finished, then 
they only get a partial receipt.  There's also not an easy way to 
determine if all the web service calls are finished, so I can't 
disable/enable the button based on that.

Is there any easy way to implement synchronous web service calls in 
Flex?  Man, if I had the option of specifying with a property whether 
or not a web service should be synchronous or asynchronous, it would 
make my life *so* much easier!


Reply via email to