不在窗体上的 Winforms 控件实例的屏幕截图
有没有办法在创建实例时获取 Windows 窗体控件(特别是 Web 浏览器)的位图呈现,但不将其添加到可见窗体中?像 WPF 的measure & 这样的机制安排这将允许我将其渲染为位图。
我的目标是 .NET 4.0,并寻找一种方法来捕获 WebBrowser 控件的内容而不显示它。
Is there a way to obtain a bitmap rendering of a Windows Forms control, specifically a WebBrowser, upon creating an instance, but not adding it to a visible form? A mechanism like WPF's measure & arrange that would allow me to render it to a bitmap.
I'm targetting .NET 4.0 and looking for a way to capture the WebBrowser control's contents without ever displaying it.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
请参阅此问题:WebBrowser.DrawToBitmap() 或其他方法?
See this question: WebBrowser.DrawToBitmap() or other methods?