當前位置:編程學習大全網 - 電腦編程 - 用VB如何只顯示網頁中指定範圍的內容?(例如圖片)

用VB如何只顯示網頁中指定範圍的內容?(例如圖片)

Private Sub WebBrowser1_DocumentComplete(ByVal pDisp As Object, URL As Variant)

Dim o() As String

If URL = WebBrowser1.Document.URL Then

If id = 1 Then

s = WebBrowser1.Document.body.innertext

I = InStr(WebBrowser1.Document.body.innertext, "截取內容") '獲得"截取內容"後面的內容

Text1.Text = Mid(s, I)

end if

End If

End Sub

  • 上一篇:如何做出正八邊形?
  • 下一篇:C語言與數控編程關系緊密嗎?
  • copyright 2024編程學習大全網