Import a function from the WebBrowser IE #3991
Replies: 2 comments
-
As I already commented on your stackoverflow post the quickest would be to convert your code to
Short answer is no. As I already commented on your I've just updated the examples see https://github.com/cefsharp/Puppeteer#dom-access At this point in time I'm looking for more GitHub Sponsors to signup so I can dedicate more time to the project. |
Beta Was this translation helpful? Give feedback.
-
I posted a bug report on the Puppeteer forums. Can you please take a look at this. (See link) Of course I would also buy you a coffee or two as described in your previous post. On GitHub Sponsors. :) |
Beta Was this translation helpful? Give feedback.
-
Hello dear developer of CefSharp,
I have the idea that a good old function from the WebBrowser from VisualStudio would fit nicely into CefSharp.
An example:
vb.net Code: (Attribute read out)
Dim ElementListe As HtmlElementCollection = Nothing
ElementListe = Form1.WebBrowser1.Document.GetElementById(TagID).GetElementsByTagName(TagName)
For Each Element As HtmlElement In ElementListe
Return Element.GetAttribute(ValueAttribute).ToString
Next
vb.net Code: (Click Button)
Dim ElementListe As HtmlElementCollection = Nothing
ElementListe = Form1.WebBrowser1.Document.GetElementById(TagID).GetElementsByTagName(TagName)
For Each Element As HtmlElement In ElementListe
Element.InvokeMember("Click")
Next
vb.net Code: (Fill Input)
Dim ElementListe As HtmlElementCollection = Nothing
ElementListe = frmMainform.WebBrowser1.Document.GetElementsByTagName(TagName)
For Each Element As HtmlElement In ElementListe
Element.SetAttribute(SetAttribute, SetAttributeValue)
Next
It's much easier to access web pages with "normal" code than via this javascript interface "ExecuteScriptAsync" or "EvaluateScriptAsync". I'm happy to bring more examples like this, but they are very similar to the ones already mentioned.
This function would certainly make it easier for beginners and those switching to CefSharp than using the Javascript functions.
Would it be possible to take over this function from the WebBrowser IE?
Greetings from Germany
Beta Was this translation helpful? Give feedback.
All reactions