[Mono-dev] Why Event not actived

Lord Steve Ataucuri Cruz sataucuri at gmail.com
Sat Sep 16 00:45:14 EDT 2006

hello, people
Thanks for its time

I am making a software and I have a class with events and I want to know
because the events in chain do not ariser? I have declared classes and what
I want to know he is because when I call to these events do not go off in
chain, something I am making bad? or deberia to make it of another form.

using System;

public delegate void EventHandlerIniciar(object sender, EventArgs a);
public delegate void EventHandlerIniciar2(object sender, EventArgs a);

public class cosa{

  public event EventHandlerIniciar termino;

  public void iniciar(){
    for(int i=0;i<=100;i++)

  public void surgioevento(){
      termino(this,new EventArgs());

public class evento{
       public event EventHandlerIniciar2 TerminoBucle;

       public evento()
             cosa c = new cosa();
             c.termino += new EventHandlerIniciar(handler);

       public  void handler(object sender,EventArgs a)
             if (TerminoBucle != null){
                    TerminoBucle(this, new EventArgs());


public class evento2{

       static void Main(){
           evento e = new evento();
           e.TerminoBucle += new EventHandlerIniciar2(handler);


       private static void handler(object s, EventArgs e){


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20060916/7bef9e5f/attachment.html 

More information about the Mono-devel-list mailing list