Thursday, December 10, 2015

The type or namespace name 'DataMember' could not be found (are you missing a using directive or an assembly reference?)

The type or namespace name 'DataMember' could not be found (are you missing a using directive or an assembly reference?) 


using System.Runtime.Serialization;

        [DataMember]
        public string FileName { get; set; }

Solution:

Add this reference to your project:

System.Runtime.Serialization (System.Runtime.Serialization.dll)


The type or namespace name 'Add this reference to your project: System.Runtime.Serialization (System.Runtime.Serialization.dll)
System.Runtime.Serialization

No comments:

Post a Comment