It seems like I’ve been attracted to errors and problems lately! = P
So, I finally took some time to research a bit of Rx.
Here is what I did:

Here is just a piece of code:
private void button1_Click(object sender, EventArgs e) { var txtc = Observable.FromEvent<EventArgs>(textBox1, "TextChanged") .Throttle(TimeSpan.FromSeconds(0.5)) .SubscribeOnDispatcher();
Now, when you start Debug (F5), I press the button, everything is fine, then I type something, poof! The form just dies quietly !!
If I run without debugging, the application works flawlessly!
Note. I removed the code from the Form.Load event due to a known error when VS did not break the exceptions in this event on Win7x64 (and yes, this is my machine)
Here is what the debug output looks like:
The stream 'vshost.NotifyLoad' (0x1438) exited with code 0 (0x0).
The stream 'vshost.LoadReference' (0x155c) exited with code 0 (0x0).
'RxWinForms.vshost.exe' (Managed (v4.0.30319)): Loaded '\ RxWinForms \ bin \ Debug \ RxWinForms.exe', loaded characters.
The first random error like "System.InvalidOperationException" occurred in System.Windows.Forms.dll
The program '[5228] RxWinForms.vshost.exe: Managed (v4.0.30319)' exited with code 0 (0x0).
The program "[5228] RxWinForms.vshost.exe: Program Trace" exited with code 0 (0x0).
gideon
source share