Collection with events

NET 4 and WPF brings us the new ObservableCollection that fire events for collection changes and contained objects property changes…but when you don’t need the “MVVM way” and bindings…it’s too much.  As it is contained in the system.dll, we can continue to use actions and event from it.

With ILSpy, I extract the code from this class to make a NotifyCollection just for the use of the items collection events. It can be used in any window service or class library. The code is below and the file is attached. NotifyCollection. Rename docx to zip. Continue reading “Collection with events”