3

I am trying to upload csv file with size 1.10 gb and i would like to allow user to upload file up to size 10 gb.

Web.config settings :

<system.web>
    <authentication mode="None" />
    <compilation debug="true" targetFramework="4.5" />
    <httpRuntime maxRequestLength="10240000" targetFramework="4.5" /> <!-- this will file upload up to 10 gb-->
  </system.web>
 <system.webServer>
    <security>
      <requestFiltering>
        <requestLimits maxAllowedContentLength="10240000" /><!-- iis setting to handle file upload up to 10 gb-->
      </requestFiltering>
    </security>
    <modules>
      <remove name="FormsAuthentication" />
    </modules>
  </system.webServer>

Error:enter image description here

Above settings are based on this reference.

I am using ng-File Upload to upload file to server.

halfer
  • 19,824
  • 17
  • 99
  • 186
I Love Stackoverflow
  • 6,738
  • 20
  • 97
  • 216
  • can you check this link please. [http://stackoverflow.com/questions/4022434/how-to-set-the-maxallowedcontentlength-to-500mb-while-running-on-iis7][1] – Ilaria Dec 28 '16 at 06:40

2 Answers2

3

Increase the value of maxAllowedContentLength. Maximum value of maxAllowedContentLength is 4,294,967,295 bytes = 3,99 gb.

hasnayn
  • 356
  • 4
  • 22
2

You can set it to 3.99 GB max. According to MSDN maxAllowedContentLength has type uint, its maximum value is 4,294,967,295 bytes = 3.99 GB

Ahmar
  • 3,717
  • 2
  • 24
  • 42