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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Image size in datagrid

Status
Not open for further replies.

peekay

Programmer
Oct 11, 1999
324
ZA
I have a webform that a client uses to submit a property listing to our property web page. In the process he uploads his photo of the property - all this I have done correctly including to test whether its a .jpg or .gif file.

I have a problem however in that I can only allow a photo of size 150x150 pixels.
1 How can I test the image file that the client uploads to see whether it is indeed 150x150.
2. Even if he uploads an image file of the wrong size - how can I resize it in my image control, be it a hyperlink or image control. I am using a hyperlink control.

Thanks.


PK Odendaal
 
If you use an image control like this

<asp: Image width="150px" height="150px"></asp:Image>

it will resize the image added to the size of the control

 
rotsey

I have done that, but the images are displayed at different sizes. Maybe a hyperlink does not support the width and height attributes.


PK Odendaal
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top