Still can't understand managing async calls

Beantwortet Still can't understand managing async calls

  • Freitag, 11. Dezember 2009 13:29
     
     
    Hello,
    I will explain better my problem in this post.

    I have to make let's say.. 5 times the same WCF  asynchronous call  in silverlight...

    let's say GetDataAsync();
                 ...
                 ...
                 GetDataAsync();

    and I want to be notified when all the 5 executions are ended. (All the complete handler executed)..

    A second problem could be to make every call at soon as the previous one has completed.

    Thank you a lot :)

Alle Antworten

  • Samstag, 12. Dezember 2009 05:11
    Besitzer
     
     
     I want to be notified when all the 5 executions are ended. (All the complete handler executed)

    Use ForkJoin: Runs all observable sequences in parallel and combines their first values. 

    > A second problem could be to make every call at soon as the previous one has completed.

    Use OnErrorResumeNext: Continues an observable sequence that is terminated normally or by an exception with the next observable sequence. 

    If you want to do more fancy synchronization, play with Observable.Join, and at Zip, CombineLatest, ...

    Hope this helps
  • Samstag, 12. Dezember 2009 12:47
     
     
    Yes, I was notified about that, but could you please post a smalll example... I can't figure out how to make the calls (Async pattern et similia...)

    Thank you a lot!!!


    BTW.. are you Erik? :)

    A good thanks! :))
  • Samstag, 12. Dezember 2009 16:26
    Besitzer
     
     Beantwortet
     but could you please post a smalll example...
    I hear and I forget. I see and I remember. I do and I understand. 
    http://en.wikipedia.org/wiki/Confucius

    You will and learn most and find great pleasure in opening Visual Studio, and figuring this out yourself based on these hints, studying the Intellisense doc comments and reading the other samples from this forum. Maybe you can even contribute your findings by adding entries to the 101 Rx samples http://rxwiki.wikidot.com/101samples.

    Wax on, wax off, wax on, wax off, wax on, wax off, ....

    • Als Antwort vorgeschlagen Richard Hein Samstag, 12. Dezember 2009 18:01
    • Als Antwort markiert AndreaPi Sonntag, 13. Dezember 2009 11:43
    •  
  • Sonntag, 13. Dezember 2009 11:42
     
     
    honored from hearing from you :)

    So I'll try my dirty bits:)

    Very excited on following what're doing!
    Greetings from Italy!