以文本方式查看主题

-  Foxtable(狐表)  (http://www.foxtable.com/bbs/index.asp)
--  专家坐堂  (http://www.foxtable.com/bbs/list.asp?boardid=2)
----  foxtable.XObject的问题  (http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&id=177223)

--  作者:tianhao0817
--  发布时间:2022/5/13 10:34:00
--  foxtable.XObject的问题
<xml><ToUserName><![CDATA[gh_a9d0fc56fe1c]]></ToUserName>
<FromUserName><![CDATA[ofRouwuV0m_ukAgGtE_YgUuvplrk]]></FromUserName>
<CreateTime>1652357098</CreateTime>
<MsgType><![CDATA[event]]></MsgType>
<Event><![CDATA[LOCATION]]></Event>
<Latitude>30.116600</Latitude>
<Longitude>120.958298</Longitude>
<Precision>15.000000</Precision>
</xml>

请问一下老师,要怎么样才可以循环上字符串里的每一项 ,我如何判断出上面这个没有aabbcc的这个信息,谢谢

Dim xo As Foxtable.XObject = Foxtable.XObject.Parse(s)

Output.Show(xo("ToUserName"))  

Output.Show(xo("aabbcc"))

[此贴子已经被作者于2022/5/13 10:34:39编辑过]

--  作者:有点蓝
--  发布时间:2022/5/13 11:05:00
--  
遍历

For Each it As Object In xo
        Output.Show(it.key & "-" & it.value)
Next

判断

Output.Show(xo("aabbcc") is nothing)