Hands-on Labs of Reactive Extensions for .NET (Rx) doesn't work
-
jeudi 7 juillet 2011 11:43
Hi,
I am using the Hands-on Labs of Reactive Extensions for .NET (Rx) PDF.
Most of the examples are not working anymore.
I'm getting some weird kind of errors.
Till Excersie 2, However I made it work.
But from Exercise 3 – Importing .NET events into Rx, it's not working anymore.
Say for the below example,
var lbl = new Label(); var frm = new Form { Controls = { lbl } }; frm.MouseMove += (sender, args) => { lbl.Text = args.Location.ToString(); }; Application.Run(frm);
The Error it's giving is :
Error 1 A local variable named 'args' cannot be declared in this scope because it would give a different meaning to 'args', which is already used in a 'parent or current' scope to denote something else C:\My Documents\Visual Studio 2010\Projects\ConsoleApplication1\ConsoleApplication1\Program.cs 15 37 ConsoleApplication1
And for the rest of the examples, this kind of more errors are going on.Any help?
Thanks & Regards, Naimish Pandya [MCTS, MCPD] http://naimishpandya.wordpress.com/
Toutes les réponses
-
mardi 4 octobre 2011 05:45No reply still??
Thanks & Regards, Naimish Pandya [MCTS, MCPD, MVP] http://naimishpandya.wordpress.com/ -
mardi 4 octobre 2011 06:26
Hi Naimish,
I don't think you read the instructions carefully enough. The default `Program.cs` is replaced by the following code:
using System.Linq; using System.Windows.Forms; class Program { static void Main() { var lbl = new Label(); var frm = new Form { Controls = { lbl } }; frm.MouseMove += (sender, args) => { lbl.Text = args.Location.ToString(); // This has become a position-tracking label. }; Application.Run(frm); } }
In this code there is only one `args` so the code compiles.Cheers.
James C-S -
jeudi 26 avril 2012 08:25
I've started working through the lab using Rx v1.0 but the document seems to be out of date, e.g. System.CoreEx no longer exists, and methods such as subscriber.Run and Observable.GenerateWithTime have disappeared. I don't see any point in proceeding with the lab if these problems are going to hinder my attempts at learning.
Is there an updated version anywhere, or can someone recommend a good Rx tutorial?
Thanks in advance
Andy
-
vendredi 27 avril 2012 05:16PropriétaireWe will update documentation in the Rx v2.0 timeframe. Thanks for reminding us and sorry for the inconvenience!
using (Microsoft.Sql.Cloud.DataProgrammability.Rx) { Signature.Emit("Bart De Smet"); }
-
mardi 19 juin 2012 22:10I assume that DEVHOL203 will be updated to actually work with the nuget libraries.
It is really frustrating to want to ramp up on a technology when examples, documentation, etc. are all over the place.

