Beispiel #1
0
        static void Main(string[] args)
        {
            EventTest et = new EventTest();

            et.Setvalue(10);
            et.ChangeNum += new EventTest.NumManidpulationHandler(EventTest.EventFired);
            et.Setvalue(100);
        }
Beispiel #2
0
        static void Main(string[] args)
        {
            var e = new EventTest(5);

            e.ChangNum += new EventTest.NumManipulationHandler(EventTest.EventFired);
            e.Setvalue(50);
            //e.Setvalue(100);

            I i = new Myclass();

            i.MyEvent += new MyDelegate(f);
            i.FireAway();
            Console.WriteLine();
        }