Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Checking file upload size

Reply
Thread Tools

Checking file upload size

 
 
Vicky
Guest
Posts: n/a
 
      02-11-2004
i have specified 10000 kbytes iin maxrequestlength , now if a file having
size more than the limit is selected and upload button is pressed then page
not found error comes.
How to check file size and restrict user before this error occurs

Vicky


 
Reply With Quote
 
 
 
 
=?Utf-8?B?QXZuZWVzaA==?=
Guest
Posts: n/a
 
      02-11-2004
By default ASP.NET has a limits of file upload size equals to 4Mb approx.
This is implemented to prevent denial of service attacks ( smebody try to bring down the server by uploading massive files).

To enable support for larger files, you should add following configuration setting value to your application ( machine's web.config file):

<configuration><system.web><httpRuntime maxRequestLength="4096" /></system.web></configuration>

Replace 4096 with higher value.

Hope this helps.

Avneesh
MCAD, MCSD.Net


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
mega pixels, file size, image size, and print size - Adobe Evangelists Frank ess Digital Photography 0 11-14-2006 05:08 PM
Upload file format checking Bryan Perl Misc 8 03-05-2006 10:24 PM
Upload a file without file Upload control - ASP.Net =?Utf-8?B?U2FyYXY=?= ASP .Net 3 08-03-2005 01:09 AM
is there a way of checking the size of the file before an upload begins Mel HTML 4 11-23-2004 12:21 AM
Upload file Check file size lawrence ASP .Net 4 06-10-2004 08:02 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57