Using CDATA with WCF REST starter kits

后端 未结 4 1143
深忆病人
深忆病人 2020-12-16 06:16

I have a service built using Preview 2 of the WCF REST starter kit, but I\'ve run into an issue with passing around XML-styled data in the calls. Here\'s my request object:<

4条回答
  •  一整个雨季
    2020-12-16 06:23

    Although this is an older post here are my 2¢. I addressed this issue by defining the data member as XmlElement.

     [DataMember(Name = "MyCData")]
            public XmlElement MyCDataField { get; set; }
    

提交回复
热议问题