Yeap, looking at that now and having little luck as well.

http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/Flex/Q_23313753.html,
 for example, shows someone with a similar problem with a similar solution. 
Here's what I've got ...

var myService:Statistics = new Statistics(null,endPoint);
var token:AsyncToken = myService.disableStatistics(user,pass,email,tArray);
token.email = email;
token.addResponder(new AsyncResponder(myResults,myFaults,token)); 

myResults and myFaults are never hit. If I use addEventListener against 
myService instead, I get the resulting data, but nothing from the 
token:AsyncToken. 

I'm not comfortable that I have the AsyncToken set up properly, since it doesnt 
make sense to make the call to myService before 'email' or 'addResponder' is 
issued, which is what I'm playing with right now.

Treffy


--- In [email protected], João Fernandes 
<joaopedromartinsfernan...@...> wrote:
>
> You can add a responder to your AsyncToken which will carry your fault and
> result handlers.
> 
> 2010/1/18 trefalgar <trefal...@...>
> 
> >
> >
> > For those wanting to follow this suggestion, there's a good example here:
> > http://livedocs.adobe.com/flex/3/html/help.html?content=data_4.html. It's
> > towards the bottom, "Using a return token".
> >
> > Unfortunately, this example doesn't appear to work for me. It uses the
> > Flex-built SOAP code and an AsyncToken to keep track of things. I don't have
> > a FaultEvent.FAULT or ResultEvent.RESULT option when adding an event
> > listener to my AsyncToken.
> >
> > Back to the drawing board I go.
> >
> > Jacob
> >
> >
> > --- In [email protected] <flexcoders%40yahoogroups.com>, João
> > Fernandes <joaopedromartinsfernandes@> wrote:
> > >
> > > > That said, since #2 doesn't tell me what user it's replying "no" to,
> > > > if I do this in a loop with 100 users, it could be replying back with
> > > > 20 "no"s and I can't tell how I'd match the replies up with the
> > requests.
> > > Yes you can, try using the asyncToken generated by
> > > service.invokeWs(user) and store your user in some property (eg.
> > > currentUser) , once you get the resultEvent, that AsyncToken will have
> > > the corresponding user stored (event.token.currentUser).
> > >
> > > --
> > >
> > > João Fernandes
> > >
> > > Adobe Certified Expert
> > > Adobe Community Expert
> > > http://www.twitter.com/joaofernandes
> > > http://www.riapt.org
> > > Portugal Adobe User Group (http://aug.riapt.org)
> > >
> >
> >  
> >
> 
> 
> 
> -- 
> 
> João Fernandes
>


Reply via email to