C# 在VB.net中解析Soap响应
下面是Soap响应XML字符串C# 在VB.net中解析Soap响应,c#,vb.net,xml-parsing,soap-client,xmldocument,C#,Vb.net,Xml Parsing,Soap Client,Xmldocument,下面是Soap响应XML字符串 <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instanc
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Header />
<soapenv:Body>
<qu:quotationResponse xmlns:qu="http://Reliance_RENEWAL_Quotation/IRenewal_Quotation">
<response><?xml version="1.0" encoding="UTF-8"?>
<RENEWAL-QUOTATION-RESPONSE>
<MESSAGE-DATA>
<ContractType>XYZ </ContractType>
<PremiumAmount>10000</PremiumAmount>
<PremiumSuspense>0.0</PremiumSuspense>
<NetAmmount>10000.0</NetAmmount>
<ContractPremiumStatus>Surrender </ContractPremiumStatus>
<ContractOwnerClientNumber>0501234</ContractOwnerClientNumber>
<OwnerName>SUDZ</OwnerName>
<LifeAssuredClientNumber>12312312</LifeAssuredClientNumber>
<LifeAssuredName>SUDZ </LifeAssuredName>
<PaidTodate>20110731</PaidTodate>
<ReinstatementFee>0.0</ReinstatementFee>
<ContractNumber>1122112211</ContractNumber>
</MESSAGE-DATA>
<ERROR-DETAILS>
<ErrorCode>No Errors</ErrorCode>
<ErrorDesc></ErrorDesc>
</ERROR-DETAILS>
</RENEWAL-QUOTATION-RESPONSE>
</response>
</qu:quotationResponse>
</soapenv:Body>
</soapenv:Envelope>
XYZ
10000
0
10000
投降
0501234
苏伊兹
12312312
苏伊兹
20110731
0
1122112211
没有错误
我需要ContractType、NetAmount等的值
我试过了,但无法解析。
解析上述xml的最佳方法是什么
请提供帮助。您可以使用XmlDocument类或XmlReader类。@CSharper:您能提供任何示例吗检查这个问题是否有用