Click to See Complete Forum and Search --> : File Upload Control


gorgeous
September 25th, 2002, 07:14 AM
Hi friends,

I am using the HTml Input File control to upload the image to the server.

Regarding this i have two problems :---

1. I need this control to be hided. In this case when I call the click event of the file control the path is set but the Form submit event is not called, instead the File control is made blank. IF the event is not called programatically (the control is visible and Browse button is clicked) the form can be submitted and works as required.

What is cause and Solution??


2. I want to set the filter for images only. How this can be done??


Regards,

Lalit

JennyM
September 25th, 2002, 07:19 AM
Use HtmlInputFile.Accept="image/*"
and
HtmlInputFile.Visible=false

Hope that helps

More examples are in MSDN if you need more