Click here to Skip to main content
15,912,021 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
how to change the dimension of image
during file upload according to specified height and Width
Posted
Updated 24-Jul-12 1:59am
v3
Comments
dimpledevani 24-Jul-12 8:08am    
try to google it, you will get your answer
AshishChaudha 24-Jul-12 8:10am    
have you googled anything?? What you have so far?

1 solution

C#
System.Drawing.Image imageToBeResized = System.Drawing.Image.FromStream(FileUpload1.PostedFile.InputStream);

Bitmap bitmap = new Bitmap(imageToBeResized, DesiredWidth, DesiredHeight);
 
Share this answer
 

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