alihamed
11-05-2003, 07:39 AM
Hi,
The problem:
I have a page where I allow users to upload an image. I perform the upload using ASPUpload code (which discountASP.net provides as well). After the upload, this ASPUpload component provides a path to an image where I now use ASPImage to perform some resizing and then re-save the file. However, what I want to do two separate re-sizing. Meaning, I like to re-size the image to 260 x 180 and also re-size the image to 70 x 60 and then save the image as two separate images. Essentially, taking the path and filename that ASPUpload provides and create two objects of the ASPImage and then do the separate resizing and save the separate images into separate directories with the same original file.
The Question:
What is the exact code I need for ASPImage to create two objects of an image from the same file name and path that I provide, perform my resizing of the images (one will be 260 x 180 and the other being a thumbnail will be 70 x 60) and then save each individual image with the same file name, but into two separate directories, different from the original directory? I appreciate your help with this; Please write the code knowing that ASPUpload will provide a path name, but obviously, you don?t need to write the code for the ASPupload component.
Thanks,
Ali
The problem:
I have a page where I allow users to upload an image. I perform the upload using ASPUpload code (which discountASP.net provides as well). After the upload, this ASPUpload component provides a path to an image where I now use ASPImage to perform some resizing and then re-save the file. However, what I want to do two separate re-sizing. Meaning, I like to re-size the image to 260 x 180 and also re-size the image to 70 x 60 and then save the image as two separate images. Essentially, taking the path and filename that ASPUpload provides and create two objects of the ASPImage and then do the separate resizing and save the separate images into separate directories with the same original file.
The Question:
What is the exact code I need for ASPImage to create two objects of an image from the same file name and path that I provide, perform my resizing of the images (one will be 260 x 180 and the other being a thumbnail will be 70 x 60) and then save each individual image with the same file name, but into two separate directories, different from the original directory? I appreciate your help with this; Please write the code knowing that ASPUpload will provide a path name, but obviously, you don?t need to write the code for the ASPupload component.
Thanks,
Ali