当我将浏览器中的网页源代码与我从下面的代码中获得的源代码进行比较时,
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
WebBrowser1.Navigate("http://www.tsetmc.com/loader.aspx?ParTree=151311&i=778253364357513")
End Sub
Private Sub WebBrowser1_DocumentCompleted(ByVal sender As System.Object, ByVal e As System.Windows.Forms.WebBrowserDocumentCompletedEventArgs) Handles WebBrowser1.DocumentCompleted
RichTextBox1.Text = WebBrowser1.Body.InnerHtml
End Sub
它有所不同。源代码不一样,我怀疑这是由于某些DOM操作引起的。
是否有可能在编程后使用javascript和/或ajax操作(使用VB.NET)获取HTML源代码?