Serialization DataMember (name) override issue
问题 I am using a DataContractJsonSerializer and have an issue with the DataMember Name. I made a base class and several derived classes. I need the derived classes because I have different json strings. I want to deserialize the json strings and therefore need different names for the datamembers. I try to change the DataMember name as in the following example: Baseclass: [DataContract] public abstract class BaseClass { [DataMember] public virtual string FirstMethod { get; protected set; } }