crop and resize images in vb and asp.net?
I need to know how to make the web application crop an image and resize it as a thumbnail to use it later on in the app开发者_如何学Clication?
You need to write a code that uses System.Drawing classes.
Edit:
Please take a look at this thread - Resize an Image C#
If you google for "crop c#" or "resize c#" you will get lots of good tutorials. :)
For example:
Crop An Image (Bitmap) in C# or VB.NET
C# Tutorial - Image Editing: Saving, Cropping, and Resizing
How to crop an image using C#?
Resizing and cropping the image is relatively easy in C#, as others have pointed out. The trouble is getting the information for what parts of the image to crop to. You will need to display the image for the user, and allow them to select the area; this will most likely happen using some JavaScript.
This site has one example of how to do this, although not a very good one. I think a much slicker one could be created by using JQueryUI's draggable features, but I'll leave that exercise up to you.
精彩评论