views:

30

answers:

2

I have a custom control, a groupbox, which reacts on key events on a assigned key. It is possible to remove this groupbox, as well as adding more dynamically. Havnt been any trouble in VS 2008 so far.

Two days ago i installed VS 2010. And i started to get multiple event fireing, and removing a groupbox did not remove the specific key events attached to it.

Where did it go wrong?

I use -= on the events present in the gruopbox code to remove them before removing the groupbox.

A: 

Are you still targeting .NET 3.5, or now .NET 4.0?

Possibly this is worth reading

http://blogs.msdn.com/cburrows/archive/2010/03/18/events-get-a-little-overhaul-in-c-4-part-iii-breaking-changes.aspx

or perhaps you always had a bug or a race condition...

http://blogs.msdn.com/ericlippert/archive/2009/04/29/events-and-races.aspx

Just guesses, I may be wrong.

Brian
A: 

Thats the strange thing.

I target the 2.0 framework for best compabillity with mono.

I checked old logs and no, no signs of racing there : /

Erik Karlsson
These kinds of remarks should be comments and not answers.
Eric