找不到DataContractJsonSerializer.net 4.0类
我正在尝试创建DataContractJsonSerialize的对象 使用System.Runtime.Serialization.Json;不工作,我正在使用.Net 4.0 我已经添加了对System.ServiceModel.Web的引用,我还使用了System.ServiceModel.Web;在我的使用语句中找不到DataContractJsonSerializer.net 4.0类,.net,.net,我正在尝试创建DataContractJsonSerialize的对象 使用System.Runtime.Serialization.Json;不工作,我正在使用.Net 4.0 我已经添加了对System.ServiceModel.Web的引用,我还使用了System.ServiceModel.Web;在我的使用语句中 我读到的每一篇文章都说要添加对System.ServiceModel.Web.dll的引用,但这并没有为我解决它根据MSDN,DataContractJsonSerialize
我读到的每一篇文章都说要添加对System.ServiceModel.Web.dll的引用,但这并没有为我解决它根据MSDN,
DataContractJsonSerializer
是在System.Runtime.Serialization.dll
中实现的:
确保有对该程序集的引用
System.Runtime.Serialization.dll
System.Runtime.Serialization.Json中使用代码>
它的DataContractJsonSerializer,你在最后缺少了r,这是一个打字错误吗?我不得不删除并重新创建了对程序集的引用,然后它工作了!