-1
這個代碼只是工作!但由於某種原因,它現在停止了工作。當我運行這個項目時,下面的代碼應該執行,但它不會!請幫忙。,不是所有的Form_Load代碼運行
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim xmldoc As New System.Xml.XmlDocument()
'Load from file
xmldoc.Load("http://sites.google.com/site/shadchanproject/Home/lots1.xml")
'Get a list of all the child elements
Dim nodelist As XmlNodeList = xmldoc.DocumentElement.ChildNodes
'Parse through all nodes
For Each outerNode As XmlNode In nodelist
ListBox1.Items.Add(outerNode.Name)
Next
End Sub
是Form_Load事件還是有線的? – 2009-06-10 05:54:44
是什麼問題?你的意思是什麼不執行?是xmldoc能夠從url加載xml嗎? – shahkalpesh 2009-06-10 05:55:41