Skip to main content
All docs
V25.1
  • .NET 8.0+
    • The page you are viewing does not exist in the .NET Framework 4.6.2+ platform documentation. This link will take you to the parent topic of the current section.

    StartupExtensions.AddXafOffice(IServiceCollection) Method

    Registers the required Office Module services in the application’s IServiceCollection.

    Namespace: DevExpress.ExpressApp.Office.Blazor

    Assembly: DevExpress.ExpressApp.Office.Blazor.v25.1.dll

    NuGet Package: DevExpress.ExpressApp.Office.Blazor

    Declaration

    public static IServiceCollection AddXafOffice(
        this IServiceCollection services
    )

    Parameters

    Name Type Description
    services IServiceCollection

    The collection of services registered in your application.

    Returns

    Type Description
    IServiceCollection

    The collection of services registered in your application. Allows you to chain further service registrations.

    Remarks

    Call this method in the Startup.ConfigureServices method when you add the Office Module to your ASP.NET Core Blazor application:

    File: MySolution.Blazor.Server\Startup.cs.

    using DevExpress.ExpressApp.Office.Blazor;
    // ...
    public class Startup {
        // ...
        public void ConfigureServices(IServiceCollection services){
            //...
            services.AddXafOffice();
        }
        // ...
    }
    
    See Also