Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6075159
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T10:27:47+00:00 2026-05-23T10:27:47+00:00

I have some custom event args: AutoOccurPerformedEventArgs : EventArgs and the same event with

  • 0

I have some custom event args:

AutoOccurPerformedEventArgs : EventArgs

and the same event with these event args is raised in 2 seperate locations I’m trying to use the Reactive Extensions to forkjoin these and then subscribe

var events = new[]
                        {
                            Observable.FromEvent<AutoOccurPerformedEventArgs>(viewModel1, "AutoOccurActionPerformed"),
                            Observable.FromEvent<AutoOccurPerformedEventArgs>(viewModel2, "AutoOccurActionPerformed"),
                        };
events.ForkJoin().Subscribe(op => IsUpdatedByAutoOccur = op.Any(observedItem => observedItem.EventArgs.IsUpdatedByAutoOccur));

My anonymous delegate in the subscribe never gets called. No exceptions are raised, the delegate just never gets invoked.

However, if I subscribe to each event individually, without ForkJoin, the events are handled correctly (although seperately)

Observable.FromEvent<AutoOccurPerformedEventArgs>(viewModel1, "AutoOccurActionPerformed")
                .Subscribe(o => IsUpdatedByAutoOccur = o.EventArgs.IsUpdatedByAutoOccur ? true : IsUpdatedByAutoOccur);

Observable.FromEvent<AutoOccurPerformedEventArgs>(viewModel2, "AutoOccurActionPerformed")
                .Subscribe(o => IsUpdatedByAutoOccur = o.EventArgs.IsUpdatedByAutoOccur ? true : IsUpdatedByAutoOccur);

Any ideas as to why ForkJoin is not working?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T10:27:48+00:00Added an answer on May 23, 2026 at 10:27 am

    Have a look at the intellisense help on the ForkJoin method. Despite the spelling error, it says:

    Runs two observable sequences in parallel and combines their last elemenets.

    Since you are doing a ForkJoin over events you will never get a result because these type of observables never complete.

    You possibly want to use Merge or CombineLatest to achieve what you want, but since you didn’t describe your intent I can’t give a better suggestion.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a custom control that implements IPostBackEventHandler. Some client-side events invoke __doPostBack(controlID, eventArgs).
I have a custom event handler, or I suppose some call it a custom
I have some custom type: [RdfSerializable] public class Item { [RdfProperty(true)] public string Name
I have some custom logic that needs to be executed every single time a
I have developed some custom DAO-like classes to meet some very specialized requirements for
I have authored some custom classes that I would like to create using XAML:
I have some projects that run on custom hardware. Now the hardware has changed,
We have a project where a vendor produces some custom code for us and
I'd like to make some custom MenuHeaders in WPF so I can have (for
I have inherited a visual studio 2003 project which uses some custom build steps.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.