拉入数据集的XML排除了一些元素

时间:2016-02-20 00:32:00

标签: c# xml web-services atom-feed

以下是我用于从Web服务中提取xml的代码:

 string ServerURl = "xxX"   
 HttpWebRequest request = (HttpWebRequest)WebRequest.Create(ServerURl);
 request.ContentType = "application/xml+atom";
 request.Credentials = CredentialCache.DefaultCredentials;
 HttpWebResponse response = (HttpWebResponse)request.GetResponse();
 var datastream = response.GetResponseStream();
 XmlReader reader = XmlReader.Create(datastream);
 ds.ReadXml(reader);

有两种类型的元素可以返回格式,如:

<m:table>
   <d:Identification m:type="Edm.Int32">12346</d:Identification>
   <d:EmployeePhone m:type="Edm.Int32">123456</d:EmployeePhone>
   <d:EmployeeName>Joe Doe</d:EmployeeName>

我注意到 m:type 的所有行都没有返回,我该如何包含这些?

0 个答案:

没有答案