Browser screenshot as bitmap in WP7

匆匆过客 提交于 2020-01-13 05:56:20

问题


I'm trying to get the screenshot of a given URL as a bitmap image on the Windows Phone. The WebBrowser class does not seem to have the DrawToBitmap method.

Any pointers on how to get this working?


回答1:


You can't take a screenshot of the WebBrowser Control as there seems to be a bug with the way it works with WriteableBitmaps. An alternative method could be to send the URL to a web service which takes a screenshot on the server and returns it back to your app.




回答2:


Use WriteableBitmap to render the WebBrowser control and its contents to a bitmap as described by Laurent's article Taking a screenshot from within a Silverlight #WP7 application, which also explains how to save it to the media library.



来源:https://stackoverflow.com/questions/4965749/browser-screenshot-as-bitmap-in-wp7

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!