解析XML,急急急~~~~
我调用了一个Web Service,可是它返回的是一个XML格式的字符串!
如:
<?xml version= "1.0 " encoding= "UTF-8 "?>
<root lines= "2 " status= "0 ">
<linkman info= "ID:06e0c7c91059e68701105d27c2b80308,姓名:朱佳,部门:null ">
<linkman info= "ID:06e0c7c90c19b934010c2321684007c3,姓名:朱佳,部门:null "/>
</root>
我应该怎么快速解析?
------解决方案--------------------Dim d As XmlDocument = New XmlDocument
d.Load(strXML)
Dim ns As XmlNodeList = d.SelectNodes( "/root/linkman ")
For Each x As XmlNode In ns
Response.Write(x.Attributes( "info ").Value)
Next