Unable to upload file on server

P

paras

I am using File Upload Control to upload file on server. If size of
the file exceeds maxRequestLength property in httpRuntime section of
my configuration file, then DNS error is thrown. how can i restrict
the user from selecting a file of specific size.

Best solution would be if i can restrict the user on client side. If
not possible, then how can i handle the DNS error on server?

Any help would be greatly appreciated.

Best Regards,
Paras Shah
(VMF SoftTech Ltd.)
 
H

Hermit Dave

you will have to rely on some funky javascript on client to block the submit
if the client is uploading a file bigger than xxxxx

there was a post a few weeks back... on a similar issue

check this line.. its got some javascript to open the file and check its
size...
https://lists.latech.edu/pipermail/javascript/2003-April/005190.html

http://www.dotnet247.com/247reference/msgs/19/95057.aspx

http://codingforums.com/showthread.php?s=&threadid=30449

hope this helps... never tried using client side validation on filesize...

--
Regards,
HD
Once a Geek.... Always a Geek
paras said:
I am using File Upload Control to upload file on server. If size of
the file exceeds maxRequestLength property in httpRuntime section of
my configuration file, then DNS error is thrown. how can i restrict
the user from selecting a file of specific size.

Best solution would be if i can restrict the user on client side. If
not possible, then how can i handle the DNS error on server?

Any help would be greatly appreciated.

Best Regards,
Paras Shah
(VMF SoftTech Ltd.)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top