To increase the MaxFileSize property to support up to 2GB in your ASP.NET code using the Telerik RadAsyncUpload control, you should specify the MaxFileSize in bytes. Since 1GB equals 1,073,741,824 bytes, for 2GB, you would set it to 2,147,483,648 bytes.
However, you should be aware that increasing the MaxFileSize to such a large value also requires adjustments in the web server settings to handle such large uploads. For ASP.NET applications, this involves changes in the web.config file to increase the maxRequestLength (for IIS 7+) and the maxAllowedContentLength settings.
Here is how you would modify your RadAsyncUpload control and what you should add to your web.config:
web.config Modifications You need to modify the httpRuntime and requestFiltering settings in your web.config file:
<configuration><system.web><!-- The maxRequestLength is in kilobytes (KB) --><httpRuntimemaxRequestLength="2097152"executionTimeout="3600" /></system.web><system.webServer><security><requestFiltering><!-- The maxAllowedContentLength is in bytes --><requestLimitsmaxAllowedContentLength="2147483648" /></requestFiltering></security></system.webServer></configuration>
1 Answer, 1 is accepted
0
Ivan Danchev
Telerik team
answered on 30 Jun 2015, 12:42 PM
Hello,
RadAsyncUpload for ASP.NET AJAX has a MaxFileSize property, which specifies the maximum size of each of the uploaded files in bytes. Unlike RadUpload for Silverlight it does not have a MaxUploadSize property.
Regards,
Ivan Danchev
Telerik
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Feedback Portal
and vote to affect the priority of the items
<telerik:RadAsyncUpload ID="RadAsyncUpload1" runat="server" MaxFileInputsCount="10"
MaxFileSize="524288000" MultipleFileSelection="Automatic" OnClientFileSelected="fileSelected"
OnClientFileUploaded="fileUploaded" EnableViewState="False">
Hi Deepak,
To increase the MaxFileSize property to support up to 2GB in your ASP.NET code using the Telerik RadAsyncUpload control, you should specify the MaxFileSize in bytes. Since 1GB equals 1,073,741,824 bytes, for 2GB, you would set it to 2,147,483,648 bytes.
However, you should be aware that increasing the MaxFileSize to such a large value also requires adjustments in the web server settings to handle such large uploads. For ASP.NET applications, this involves changes in the web.config file to increase the maxRequestLength (for IIS 7+) and the maxAllowedContentLength settings.
Here is how you would modify your RadAsyncUpload control and what you should add to your web.config:
RadAsyncUpload Control Modification
<telerik:RadAsyncUpload ID="RadAsyncUpload1" runat="server" MaxFileInputsCount="10" MaxFileSize="2147483648" MultipleFileSelection="Automatic" OnClientFileSelected="fileSelected" OnClientFileUploaded="fileUploaded" EnableViewState="False">
web.config Modifications
You need to modify the httpRuntime and requestFiltering settings in your web.config file:
<configuration> <system.web> <!-- The maxRequestLength is in kilobytes (KB) --> <httpRuntime maxRequestLength="2097152" executionTimeout="3600" /> </system.web> <system.webServer> <security> <requestFiltering> <!-- The maxAllowedContentLength is in bytes --> <requestLimits maxAllowedContentLength="2147483648" /> </requestFiltering> </security> </system.webServer> </configuration>