Skip to main content
A newer version of this page is available. .

StartupExtensions.RemoveDefaultReportingControllers(IMvcBuilder) Method

Removes the default reporting controllers from an application.

Namespace: DevExpress.AspNetCore.Reporting

Assembly: DevExpress.AspNetCore.Reporting.v19.1.dll

NuGet Package: DevExpress.AspNetCore.Reporting

Declaration

public static IMvcBuilder RemoveDefaultReportingControllers(
    this IMvcBuilder builder
)

Parameters

Name Type Description
builder IMvcBuilder

The IMvcBuilder instance this method extends.

Returns

Type Description
IMvcBuilder

A IMvcBuilder that can be used to further configure the MVC services.

Remarks

When you add the DevExpress.AspNetCore.Reporting assembly to your application, the default MVC reporting controllers are registered automatically.

If you want to use your custom controllers to process requests, call the RemoveDefaultReportingControllers method to unregister the default controllers.

using DevExpress.AspNetCore;
using DevExpress.AspNetCore.Reporting;
//... 

public class Startup {
//... 
    public void ConfigureServices(IServiceCollection services) {
        services.AddDevExpressControls();
        services.AddMvc().RemoveDefaultReportingControllers(); 
    }
//...    
}

To implement custom MVC reporting controllers:

See Also