I am working with querying elements from various websites and I am using Chromium from Webview and I get all the Html modified by the Javascript and I need to load that Text from the retrieved Html into an HTML Document and the way I do it is by doing this:
Public Sub Descarga_Html1()
Dim IE_Webbrowser As New WebBrowser
Dim Contenido_HTMl As String
Contenido_HTMl = Form2.WebView1.GetSource.ToString
'Dim htmldoc As HtmlDocument
Dim Datos As String
Datos = Contenido_HTMl
IE_Webbrowser.ScriptErrorsSuppressed = True
IE_Webbrowser.DocumentText = Datos
IE_Webbrowser.Document.OpenNew(True)
IE_Webbrowser.Document.Write(Datos)
Espera(2000)
Htmldoc = IE_Webbrowser.Document
IE_Webbrowser.DocumentStream.Close()
IE_Webbrowser.Dispose()
end sub
but doing it this way leads me to Error:
System.OutOfMemoryException
From the amount of queries and the load of the Webbrowser, for that reason I would like to have the idea of how to pass that Text that contains the HTML directly to an HTML Document, thank you very much.