I need to somehow do a work around with an asp.net File Uploader so it can take more than 4gb of multiple files. Is there any way to set the web.config or write a C# function that just bypasses the Max Limit of File space that is used by ASP.Net and IIS 7? I tried to look at this http://msdn.microsoft.com/en-us/library/hh195568.aspx but I have no idea how to use the function. Please help, anyone with information about a work around that would be great since microsoft has put limits I'm guessing there has to be something out there that can bypass the limitations.
1 Answer
Unfortunately maxRequestLength is an variable of Int32 type (maximum value is 2147483647 - 0x7FFFFFFF)
But if you want to extend maxRequestLangh for your application then you can do that by adding couple of attributes to your httpRuntime in web.config:
<httpRuntime maxRequestLength="<size in bytes>" executionTimeout="<timeout in seconds>" />
Here is an example (2 gb of max lenght and about 10 minutes of timeout):
<httpRuntime maxRequestLength="2147483647" executionTimeout="600" />
Also you need to add security part to system.webServer:
<security>
<requestFiltering>
<requestLimits maxAllowedContentLength="2147483647" />
</requestFiltering>
</security>
Might be useful: