Cannot serialize exception: .Data property is IDicionary -> subclass XmlSerializer?

cjard

Well-known member
Joined
Apr 25, 2006
Messages
7,081
Programming Experience
10+
Cannot serialize exception: .Data property is IDicionary -> subclass XmlSerializer?

Guys..

I'm having a small prob where I am running a process and logging the XML it makes into a table in Oracle where one field is XMLtype (so xml have to go in there)

When I hit an exception i want to log into that table, and I figured "why not jsut serialize the Exception to XML and store it?"
But I cant because some property is an IDictionary and the XmlSerializer wont serialize it.

I dont care about the property, but I cant program in advance or edit microsoft's framework code so that it is XmlIgnore, so how do I set/upgrade the XmlSerializer to ignore elements it cannot serialize instead of throwing an exception?

Thanks in advance
 
Back
Top