Last post May 25, 2008 02:08 PM by MightyJay
May 24, 2008 11:04 AM|TheEagle|LINK
I am making a Forum in asp.net 2 and I wonder how could I be sure that the size of the image the user will enter as a Avatar will be less than maximum and without stretching the image? I read a thread in this website about CreateThumb method but I think
it does stretch the image.
May 24, 2008 03:57 PM|MightyJay|LINK
If you load the image into a Bitmap class (for example using the upload stream if you allow the user to upload the file, or using a WebRequest if you allow linking to images on other sites), you can check the Width and Height properties.
May 25, 2008 11:09 AM|TheEagle|LINK
thank you for your respond and solution...
can you provide me a link to an article or a simple example about the identical way to let the websites users to upload their avatar images?.
May 25, 2008 02:08 PM|MightyJay|LINK
I'm currently in quite a hurry, but if you do a google search on "asp.net image upload" or something, you get tons of articles. Also, on this very forum there are a lot of threads with code detailing resizing of images (so you can resize larger images to
your desired avatar size).