c# 3.0 - Problem with XML Serialization: Must implement default access descriptor in -


I have an excuse when trying to serialize a stack in Visual Studio 2008, C # 3.5

< P> Here's some sample code.

  & gt; 1 CardDNKK = New CardDN (12, CardDN. UtyType Club); & Gt; 2 stacks & lt; CardDN & gt; Kk1 = new stack & lt; CardDN & gt; (); & Gt; 3KK1 Push (K.K.); & Gt; 4 & gt; 5 XML Serializer SerialLark = New XML Surgery (kk1.GetType ()); & Gt; 6 string vents auxSerializedk = new stringwriter (); & Gt; 7 Serializer. Serialize (Ox Serialized, KK1);  

This fails in line 5. The exception is:

The system implementing the DB is defined and the system. oath. Generic. Stack 1 [[Black Jack.CardDN, DN-Blackjack, Version = 1.0.0.0, Culture = Neutral, PublicK-Token = Null]] Porchelle Hereda de Ikling.

There is something like this in English:

"The default access descriptor in the system is required to implement Colllections.Generic.Stack11 [[BlackJack.CardDN, DN_BlackJack, Version = 1.0.0.0, Culture = Neutral, PublicKeyToken = null]] Because ICollection is inherited.

I have read that these lists can be XML-serialized but the dictionary I do not think there's a heap. How can I "apply the default access descriptor"?

Many a stack is needed. Do not want to use any list.

Any thoughts Thanks?

As mentioned here: Stack does not apply the required default accessor For clarification, you should check with Pelhoros because he also answered my question.


Comments

Popular posts from this blog

MySql variables and php -

url rewriting - How to implement the returnurl like SO in PHP? -

Which Python client library should I use for CouchdB? -