Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dynamically Formatting Pictures

Status
Not open for further replies.

kliz0328

Programmer
Nov 7, 2005
138
0
0
US
I have a site where users can upload pictures. My question is...Is there anyway to dynamically format these pictures. I assume people will be uploading pictures of all different sizes, and if they are a rectangular shape they will get skewed if I make the height unproportional to the width. Is there a way to check the dimensions of a picture through .Net coding?
 
Yes, check out the System.Drawing.Image class


____________________________________________________________

Need help finding an answer?

Try the Search Facility or read FAQ222-2244 on how to get better results.

 
Is this the best way to go about formatting pictures in a website, They are profile pictures and will have to be trimmed to fit a 100 x 100 frame, or is there a bettter way?
 
That's a pretty good method I think. You could create a "thumbnail" page that resizes each image on the fly and simply call this page from the "src" attribute of each Image control.


____________________________________________________________

Need help finding an answer?

Try the Search Facility or read FAQ222-2244 on how to get better results.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top