I can\'t find the namespace to use for [DataContract] and [DataMember] elements. According to what I\'ve found, it seems that adding the following
[DataContract]
[DataMember]
First, I add the references to my Model, then I use them in my code. There are two references you should add:
using System.ServiceModel; using System.Runtime.Serialization;
then, this problem was solved in my program. I hope this answer can help you. Thanks.