Generics Serialization Exception
- From: ashraftm@xxxxxxxxx
- Date: 3 May 2006 12:03:19 -0700
Hi,
I am getting following error while XMLSerialization a class with
nullable generic member.
Public Class Car {
[XmlAttribute]
public Nullable<decimal> Meter;
}
Car car = new Car();
car.Meter = null;
XmlSerializer xml = new XmlSerializer(typeof(Car)); // Error
here.........
xml.Serialize(writer, car);
If I remove [XmlAttribute] then no problem it works. otherwise folowing
exception occurs "InvalidOperationException was unhandled".
thank you.
Achu.
.
- Follow-Ups:
- Re: Generics Serialization Exception
- From: Achu
- Re: Generics Serialization Exception
- Prev by Date: System.Configuration.ConfigurationSettings.AppSettings.Get(...)
- Next by Date: Default property display in debug windows
- Previous by thread: System.Configuration.ConfigurationSettings.AppSettings.Get(...)
- Next by thread: Re: Generics Serialization Exception
- Index(es):
Relevant Pages
|