Click here to Skip to main content
15,881,803 members
Please Sign up or sign in to vote.
2.00/5 (1 vote)
See more:
Hi friends:

I have a question now, need to resolve it!

I want to produce a picture from a web page, let us to make a example: Current codeproject page, I want to change the web page into a static picture, and include all of page contents.

Now, I know that can use WebBrowser Control to produce the picture, but it have some defects. so, I need others methods, hope you can help me to resolve the matter!!!

Thanks in advance!!!

BR,
Bo
Posted
Comments
Aaron Bo 21-Jul-14 22:45pm    
I am sorry for my forgetting some information, the firstly, I need to mass-produced image simultaneously, so I maybe need to produce image from Memory. The others thing, because I need get image from web page, so I want to know if IE provide relative interface to produce image.!!!

Thanks!

The article Various methods for capturing the screen explains some interesting methods.

If you need all webcontent than curl is your first choice.
 
Share this answer
 
Look into the CDHtmlDialog class to display the html page(s). That class is very easy to use. You can find code relating to screen shots here.
 
Share this answer
 
Comments
Aaron Bo 21-Jul-14 23:15pm    
Thanks! but, the resolution is not my wanted answer!
But, thank you very much!
hi friends:

I have resolve it problem by myself!

C#

Use winform webbrowser control,

Bitmap bitmap = new Bitmap(wb.Width, wb.Height);
wb.DrawToBitmap(bitmap, new Rectangle(0, 0, wb.Width, wb.Height));
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900