Answer the question
In order to leave comments, you need to log in
Why did browser.FrameLoadEnd stop working properly?
Like before, everything was more or less normal, it worked 2 times (at the beginning and end of the download) and normally, but now it only works at the beginning, when the html is empty. What's wrong?
public Form1()
{
InitializeComponent();
InitializeChromium();
browser.FrameLoadEnd += WebBrowserFrameLoadEnded;
}
private void WebBrowserFrameLoadEnded(object sender, FrameLoadEndEventArgs e)
{
Task.Run(async () => html = await browser.GetSourceAsync());
MessageBox.Show(html); // html = null
}
Answer the question
In order to leave comments, you need to log in
Task.Run(async () => html = await browser.GetSourceAsync());
MessageBox.Show(html); // html = null
html = await browser.GetSourceAsync()
MessageBox.Show(html);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question