2 // Tests the syntax for delegates and events
6 delegate void ClickEvent ();
9 public event ClickEvent Clicked;
11 public void DoClick ()
19 static bool called = false;
23 Button b = new Button ();
25 b.Clicked += delegate {
26 Console.WriteLine ("This worked!");