Click here to Skip to main content
15,916,945 members
Home / Discussions / C#
   

C#

 
GeneralRe: Text file to multidimensional array help needed! Pin
harold aptroot21-Mar-10 4:42
harold aptroot21-Mar-10 4:42 
GeneralRe: Text file to multidimensional array help needed! Pin
Not Active21-Mar-10 4:45
mentorNot Active21-Mar-10 4:45 
AnswerRe: Text file to multidimensional array help needed! Pin
Rod Kemp21-Mar-10 4:03
Rod Kemp21-Mar-10 4:03 
GeneralRe: Text file to multidimensional array help needed! Pin
venomation21-Mar-10 4:31
venomation21-Mar-10 4:31 
GeneralRe: Text file to multidimensional array help needed! Pin
harold aptroot21-Mar-10 4:51
harold aptroot21-Mar-10 4:51 
QuestionCollectionBase and Updating an Item Pin
Ryan Minor21-Mar-10 1:57
Ryan Minor21-Mar-10 1:57 
AnswerRe: CollectionBase and Updating an Item Pin
Not Active21-Mar-10 3:53
mentorNot Active21-Mar-10 3:53 
AnswerRe: CollectionBase and Updating an Item [modified] Pin
DaveyM6921-Mar-10 3:57
professionalDaveyM6921-Mar-10 3:57 
Not that I know of. There are two easy options.

1. If you are using .NET framework 3.5 then add a reference to WindowsBase to your project. You can then use System.Collections.ObjectModel.ObservableCollection<T> which has an event CollectionChanged which should do what you want.

2. Make your own generic class and implement ICollection<T> and possibly ICollection. You can simply wrap a List<T> in this class to make implementation easier. Now you have control over all items in/out of the collection so can raise custom events as you like.

[Edit]
I've just had a look at the CollectionBase class and you should be able to override the necessary methods as they are protected virtual and raise your own event(s).
OnClear, OnInsert, OnRemove, OnSet
All these also have a protected virtual OnxxxComplete method too.
[/Edit]
Dave

Binging is like googling, it just feels dirtier. (Pete O'Hanlon)

BTW, in software, hope and pray is not a viable strategy. (Luc Pattyn)
Why are you using VB6? Do you hate yourself? (Christian Graus)

modified on Sunday, March 21, 2010 10:09 AM

Questionc# & oracle Pin
amer shammout21-Mar-10 0:18
amer shammout21-Mar-10 0:18 
AnswerRe: c# & oracle Pin
Not Active21-Mar-10 1:50
mentorNot Active21-Mar-10 1:50 
QuestionHow to Dynamic add html in GridView by c# code???? Pin
mimimimilaw20-Mar-10 20:30
mimimimilaw20-Mar-10 20:30 
AnswerRe: How to Dynamic add html in GridView by c# code???? Pin
Rod Kemp20-Mar-10 21:10
Rod Kemp20-Mar-10 21:10 
QuestionStop files being deleted ? Pin
BuggingMe20-Mar-10 12:42
BuggingMe20-Mar-10 12:42 
AnswerRe: Stop files being deleted ? Pin
Not Active20-Mar-10 12:56
mentorNot Active20-Mar-10 12:56 
GeneralRe: Stop files being deleted ? Pin
BuggingMe20-Mar-10 13:09
BuggingMe20-Mar-10 13:09 
GeneralRe: Stop files being deleted ? Pin
Not Active20-Mar-10 13:36
mentorNot Active20-Mar-10 13:36 
GeneralRe: Stop files being deleted ? Pin
BuggingMe20-Mar-10 13:42
BuggingMe20-Mar-10 13:42 
Question.net create table of contents for Sql server report service 2008 Pin
jassiedog20-Mar-10 11:29
jassiedog20-Mar-10 11:29 
QuestionViewing SSL Certificate - C# Webbrowser Control PinPopular
Jon Braunsma20-Mar-10 5:44
Jon Braunsma20-Mar-10 5:44 
QuestionStatic Member and Inheritance Pin
Tony Richards20-Mar-10 4:54
Tony Richards20-Mar-10 4:54 
AnswerRe: Static Member and Inheritance Pin
Luc Pattyn20-Mar-10 5:28
sitebuilderLuc Pattyn20-Mar-10 5:28 
AnswerRe: Static Member and Inheritance Pin
Giorgi Dalakishvili20-Mar-10 6:16
mentorGiorgi Dalakishvili20-Mar-10 6:16 
AnswerRe: Static Member and Inheritance Pin
Bernhard Hiller21-Mar-10 21:42
Bernhard Hiller21-Mar-10 21:42 
QuestionAnimated GIF Pin
Joseph M. Ziemianski20-Mar-10 4:42
Joseph M. Ziemianski20-Mar-10 4:42 
AnswerRe: Animated GIF Pin
The Man from U.N.C.L.E.20-Mar-10 5:04
The Man from U.N.C.L.E.20-Mar-10 5:04 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.