Increase upload limit

This might be more of a generic .NET Core question.
Hopefully, someone had the same problem and found a solution :wink:

I'm using the RadzenUpload component. It works fine when I don't upload too much (< 32MB).
I've been searching how to increase this limit. So far I tried, without result:

  1. In Startup ConfigureServices: services.AddSignalR(e => e.MaximumReceiveMessageSize = 102400000)
  2. In Startup ConfigureServices: services.Configure<FormOptions>(options => { // Set the limit to 512 MB options.MultipartBodyLengthLimit = 536870912; });
  3. In Startup Configure: app.Use(async (context, next) => { context.Features.Get<IHttpMaxRequestBodySizeFeature>() .MaxRequestBodySize = null; await next.Invoke(); });
  4. In my Upload controller: [DisableRequestSizeLimit]
  5. In Program CreateHostBuilder: webBuilder.ConfigureKestrel((context, options) => { options.Limits.MaxRequestBodySize = null; })

I'm facing this limit in my Visual Studio environment as well as on Azure.

Please advice.

It is indeed a generic .NET Core question. The RadzenUpload posts to a specified url (usually a controller). Hence look for a solution how to increase the upload file size in ASP.NET MVC Core.

Thanks for the reply and the post. I tried those settings but it doesn't change anything.
I reposted this question on StackOverflow, since it is a generic question.

Following the link provided by Paul & doing a bit of research, I found that when hosting a Blazor application on IIS you need to do 2 things to increase the upload limit to 100MB:

  1. Add the following to the web.config file:
<security>
 <requestFiltering>
  <requestLimits maxAllowedContentLength="104857600" />
 </requestFiltering>
</security>
  1. Add the following code in Startup.Custom.cs:
    public partial class Startup
    {
        partial void OnConfigureServices(IServiceCollection services)
        {
            services.Configure<IISServerOptions>(options =>
            {
                // 100 MB
                options.MaxRequestBodySize = 104857600;
            });
        }
    }

I hope this helps!