Reputation: 2713
I'm developing a .NET 2.0 WinForms application. It previously included the standard Microsoft ActiveX WebBrowser control, but I'm investigating alternatives.
What I need to do:
Use the WebBrowser as a standard web browser control in the application
Be able to use it in the background too- e.g., create the control, render the webpage and output the result to an image (using .DrawToBitmap), without the control ever being attached to a form.
Hook into various events in the lifecycle- mainly DocumentCompleted.
Webpages can be loaded (or reloaded) every 30 seconds or so, either through a new instance of the control or using the existing control. The application can remain running for long and indefinite periods of time.
Must work with .NET 2.0. No 3.0+ or WPF stuff.
The only three controls I've been able to find so far all have rather critical issues that prevent me from going forward:
Microsoft ActiveX WebBrowser - Has a huge memory leak that makes it unsuitable for running for long periods of time.
WebKit.NET - As far as I've been able to establish this has to be attached to a form before any rendering is done, making it useless for the thumbnail generation piece. Also seems to suffer from memory leaks.
GeckoFX - Works best for me, but does not properly support threading (which is critical for the thumbnail generation piece).
Any other alternatives out there?
Upvotes: 1
Views: 1557
Reputation: 416149
Can you embed WebKit.Net in a form that's shown way off the visible area of the screen?
You might also look at Mono.WebKit or Mono.Mozilla, though I've never used any of these.
Upvotes: 2