This website completely moved to new platform. For latest content, visit

Search this Site

11 Dec 2012


How to upload large/big files in ?

In Previous posts i have explained about  simple example for UPLOADING FILES IN ASP.NET  and  UPLOADING DOC / DOCX FILES IN ASP.NET . Actually the default maximum size of files that can be uploaded in ASP.NET is  4MB ( 1024*4 maxRequestLength=4096 ) . So, if we try to upload the files more than 4MB , then it will give a runtime error . We can also change the maxRequestLength by writing a Line of code in Web.Config file. For this , for example if we want to accept the maximum file size is 500MB then, we have to write
     <httpRuntime executionTimeout="3600" maxRequestLength="512000"/>

The above code accepts the maximum file size of maxRequestLength= 500MB   (500*1024) . Hence we can set the maxRequestLength as per our  our requirements.