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 4597570
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T23:16:33+00:00 2026-05-21T23:16:33+00:00

I am trying to play with the reactive extension hands on lab but could

  • 0

I am trying to play with the reactive extension hands on lab but could not register using the FromEvent API (I am getting compile time exception). I want to receive events when the textchanged property is invoked on the text box control, can someone suggest what am i doing wrong on the conversion via FromEvent API? I some how cannot type cast or convert from TextChangeEventArgs/EventHandler to EventHandler – please show me the right way to do it. Thanks.

        internal delegate void TextChangedEventArgs(object sender, EventArgs e);
        var txt = new TextBox();

        var form = new Form
                      {
                          Controls = { txt }
                      };


        var subscription = Observable.FromEvent<EventHandler, TextChangedEventArgs>(
           x => (a, b) => new EventHandler(), ??????
           x => txt.TextChanged += x, 
           x => txt.TextChanged -= x
           );

       IDisposable eventSubscription = subscription.Subscribe(
           x => Console.WriteLine("Subscriber Got " + x),
           x => Console.WriteLine("An exception has occured" + x),
           () => Console.WriteLine("Action completed"));

        Console.WriteLine("in here");
       using (new CompositeDisposable(eventSubscription)) { Application.Run(form); }

        Console.ReadKey();
  • 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-21T23:16:34+00:00Added an answer on May 21, 2026 at 11:16 pm

    Try this:

    var subscription = Observable.FromEventPattern<TextChangedEventArgs>(txt, "TextChanged"); 
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to play a video file using JMF but it gives me
While trying to play video using media player, I am getting this error: Unable
I'm trying to play a video using vlcj inside a JPanel but it doesn't
I am trying to play mp4 video using html5 video tag. But in FF
I am trying to play and audio file using DirectX dll. Audio.FromFile(Message 1.mp3).Play(); But
I'm trying to play a youtube video on my Android app, but I can't
I am trying to play a song from my iPhone music library using AVPlayer.
I'm trying to play a video using opencv (the video is an avi file
I'm trying to play a sound on a button click i'm using: -(IBAction)sound {
I'm trying to play an RTMP encoded with h264 using the Flash Player 11

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.