Serializing System.Collections.Specialized.NameObjectCollectionBase

  • Thread starter Thread starter Rein Petersen
  • Start date Start date
R

Rein Petersen

Hi Everyone!

I hope someone may have experience serializing a NameObjectCollectionBase
(System.Collections.Specialized) and can advise me as to why I receive this
error (below) when I try to serialize my instance:

System.InvalidOperationException: You must implement a default accessor on
System.Collections.Specialized.NameObjectCollectionBase because it inherits
from ICollection.



How can I "implement" a default accessor?

Rein
 
Rein,

I think that by default accessor they mean an indexer, one which takes
an integer as the indexer. This accessor should be type-safe as well.

Hope this helps.
 
Back
Top