Event handler firing multiple times.

  • Thread starter Thread starter schiefaw
  • Start date Start date
S

schiefaw

Hello,

I created a custom event "Public Event ApprovalChangedEvent()" and set
a function to catch it "Private Sub laset_ApprovalChangedEvent()
Handles laset.ApprovalChangedEvent".

The problem is that the handler is invoked five times. I have set
breakpoints so I can see the the event is only raised once. The handler
itself just sets some labels, so it isn't doing anything to invoke
itself. In fact, it really doesn't cause a real problem in this
particular case. But, I want to find out what to do about it if it
happens again.

Does anyone have any suggestions on what I can do to track this issue
down?

Thanks
 
Do you ever use the AddHandler statement to wire up the event or do you
always use the Handles clause?

Could there be multiple objects that hook into the event handler?
 
I always (so far at least0 use the handles clause. After reading
through similar news postings, I went through the code looking for
anything else that would be an additional hook but I found nothing. I
can't find anything that would cause this event to fire more often. I
should mention that this is on a very complex page with many user
controls. But, the event is a custom event only used in one place. So,
I am totally lost.

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top