I have these 3 classes:
Class Image : Asset
Class Sound : Asset
Class Video : Asset
everything serializes ok but when i create this item:
Class Master
List<Asset> assets //property
an instance of this class for example:
Image i = new Image();
Sound s = new Sound();
Video v = new Video();
Master m = new Master( new List<Asset>{i,s,v} )
it does not serialize with exception "InvalidOperationException-There was an error generating the XML document" and in the innerException : {"The type MyApplication.Video was not expected. Use the XmlInclude or SoapInclude attribute to specify types that are not known statically."}
.. any idea??