Here is a piece of sample code to explain my question:
public class TheBaseClass
{
public list<int> BaseClassList {get; set;}
}
public class TheDerivedClass : TheBaseClass
{
//here I want to indicate the XmlSerializer to serialize the 'BaseClassList' with a different name 'DerivedClassList'
}
I know how to do this when the variable is in the same class by using [XmlElement( ElementName = "DesiredVarName")]
but want to know if it is possible to do this in a derived class at all? If yes, how?