skip navigation
  • Product Bundles

    DevCraft

    All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:

    • AI Coding Assistants
    • Embedded Reporting
    • Document Processing Libraries
    • SSO Account Sign-in

    Web

    Kendo UI UI for Angular UI for Vue UI for jQuery KendoReact UI for Blazor UI for ASP.NET Core UI for ASP.NET MVC UI for ASP.NET AJAX

    Mobile

    UI for .NET MAUI

    Document Management

    Telerik Document Processing

    Desktop

    UI for .NET MAUI UI for WinUI UI for WinForms UI for WPF

    Reporting

    Telerik Reporting Telerik Report Server

    Testing & Mocking

    Test Studio Telerik JustMock

    CMS

    Sitefinity

    AI Productivity Tools

    AI Coding Assistants

    UI/UX Tools

    ThemeBuilder Design System Kit Templates and Building Blocks

    Debugging

    Fiddler Fiddler Everywhere Fiddler Classic Fiddler Everywhere Reporter FiddlerCore

    Free Tools

    KendoReact Free VB.NET to C# Converter Testing Framework
    View all products
  • Overview
  • Demos
    • Roadmap
    • Release History
  • Docs & Support
  • Pricing
  • Shopping cart
    • Account Overview
    • Your Licenses
    • Downloads
    • Support Center
    • Forum Profile
    • Payment Methods
    • Edit Profile
    • Log out
  • Login
  • Contact Us
  • Try now

Class WorkbookFormatProvidersManager

Manages the global registry of workbook format providers, enabling registration, discovery by extension, and import/export operations using the registered providers.

Inheritance
System.Object
WorkbookFormatProvidersManager
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Telerik.Windows.Documents.Spreadsheet.FormatProviders
Assembly: Telerik.Windows.Documents.Spreadsheet.dll

Syntax

public class WorkbookFormatProvidersManager

Properties

FormatProviders

Gets the collection of all format providers registered with the application-wide manager.

Declaration
public static IEnumerable<IWorkbookFormatProvider> FormatProviders { get; }
Property Value
System.Collections.Generic.IEnumerable<IWorkbookFormatProvider>

The format providers.

Methods

Export(Workbook, String, Stream)

Exports a workbook to a stream using the format provider registered for the specified file extension.

Declaration
[Obsolete("The method is obsolete. Please use Export(Workbook workbook, string extension, Stream output, TimeSpan? timeout) instead.")]
public static void Export(Workbook workbook, string extension, Stream output)
Parameters
Workbook workbook

The workbook.

System.String extension

The file extension.

System.IO.Stream output

The output stream.

Export(Workbook, String, Stream, IEnumerable<IWorkbookFormatProvider>)

Exports a workbook to a stream using a provider from the specified collection that supports the file extension.

Declaration
[Obsolete("The method is obsolete. Please use Export(Workbook workbook, string extension, Stream output, IEnumerable<IWorkbookFormatProvider> formatProviders, TimeSpan? timeout) instead.")]
public static void Export(Workbook workbook, string extension, Stream output, IEnumerable<IWorkbookFormatProvider> formatProviders)
Parameters
Workbook workbook

The workbook.

System.String extension

The file extension.

System.IO.Stream output

The output stream.

System.Collections.Generic.IEnumerable<IWorkbookFormatProvider> formatProviders

The format providers to be used.

Exceptions
UnsupportedFileFormatException

Export(Workbook, String, Stream, IEnumerable<IWorkbookFormatProvider>, Nullable<TimeSpan>)

Exports a workbook to a stream with an optional timeout using a provider from the specified collection that supports the file extension.

Declaration
public static void Export(Workbook workbook, string extension, Stream output, IEnumerable<IWorkbookFormatProvider> formatProviders, TimeSpan? timeout)
Parameters
Workbook workbook

The workbook.

System.String extension

The file extension.

System.IO.Stream output

The output stream.

System.Collections.Generic.IEnumerable<IWorkbookFormatProvider> formatProviders

The format providers to be used.

System.Nullable<System.TimeSpan> timeout

The timeout after which the operation will be cancelled.

Exceptions
UnsupportedFileFormatException

System.ArgumentOutOfRangeException

The exception that is thrown when timeout is less than -1 or greater than Int32.MaxValue. Note that this upper bound is more restrictive than TimeSpan.MaxValue.

Export(Workbook, String, Stream, Nullable<TimeSpan>)

Exports a workbook to a stream with an optional timeout using the format provider registered for the specified file extension.

Declaration
public static void Export(Workbook workbook, string extension, Stream output, TimeSpan? timeout)
Parameters
Workbook workbook

The workbook.

System.String extension

The file extension.

System.IO.Stream output

The output stream.

System.Nullable<System.TimeSpan> timeout

The timeout after which the operation will be cancelled.

Exceptions
System.ArgumentOutOfRangeException

The exception that is thrown when timeout is less than -1 or greater than Int32.MaxValue. Note that this upper bound is more restrictive than TimeSpan.MaxValue.

GetProviderByExtension(String)

Retrieves the format provider that supports the specified file extension from the registered providers, or null if not found.

Declaration
public static IWorkbookFormatProvider GetProviderByExtension(string extension)
Parameters
System.String extension

The extension.

Returns
IWorkbookFormatProvider

The format provider.

GetProviderByName(String)

Retrieves the format provider with the specified name from the registered providers, or null if not found.

Declaration
public static IWorkbookFormatProvider GetProviderByName(string providerName)
Parameters
System.String providerName

Name of the provider.

Returns
IWorkbookFormatProvider

The format provider.

GetSupportedExtensions()

Enumerates all unique file extensions supported by registered format providers for import or export.

Declaration
public static IEnumerable<string> GetSupportedExtensions()
Returns
System.Collections.Generic.IEnumerable<System.String>

The supported file extensions.

Import(String, Stream)

Imports a workbook from a stream using the format provider registered for the specified file extension.

Declaration
[Obsolete("The method is obsolete. Please use Import(string extension, Stream input, TimeSpan? timeout) instead.")]
public static Workbook Import(string extension, Stream input)
Parameters
System.String extension

The file extension.

System.IO.Stream input

The input stream.

Returns
Workbook

The workbook.

Import(String, Stream, IEnumerable<IWorkbookFormatProvider>)

Imports a workbook from a stream using a provider from the specified collection that supports the file extension.

Declaration
[Obsolete("The method is obsolete. Please use Import(string extension, Stream input, IEnumerable<IWorkbookFormatProvider> formatProviders, TimeSpan? timeout) instead.")]
public static Workbook Import(string extension, Stream input, IEnumerable<IWorkbookFormatProvider> formatProviders)
Parameters
System.String extension

The file extension.

System.IO.Stream input

The input stream.

System.Collections.Generic.IEnumerable<IWorkbookFormatProvider> formatProviders

The format providers to be used.

Returns
Workbook

The workbook.

Exceptions
UnsupportedFileFormatException

Import(String, Stream, IEnumerable<IWorkbookFormatProvider>, Nullable<TimeSpan>)

Imports a workbook from a stream with an optional timeout using a provider from the specified collection that supports the file extension.

Declaration
public static Workbook Import(string extension, Stream input, IEnumerable<IWorkbookFormatProvider> formatProviders, TimeSpan? timeout)
Parameters
System.String extension

The file extension.

System.IO.Stream input

The input stream.

System.Collections.Generic.IEnumerable<IWorkbookFormatProvider> formatProviders

The format providers to be used.

System.Nullable<System.TimeSpan> timeout

The timeout after which the operation will be cancelled.

Returns
Workbook

The workbook.

Exceptions
UnsupportedFileFormatException

System.ArgumentOutOfRangeException

The exception that is thrown when timeout is less than -1 or greater than Int32.MaxValue. Note that this upper bound is more restrictive than TimeSpan.MaxValue.

Import(String, Stream, Nullable<TimeSpan>)

Imports a workbook from a stream with an optional timeout using the format provider registered for the specified file extension.

Declaration
public static Workbook Import(string extension, Stream input, TimeSpan? timeout)
Parameters
System.String extension

The file extension.

System.IO.Stream input

The input stream.

System.Nullable<System.TimeSpan> timeout

The timeout after which the operation will be cancelled.

Returns
Workbook

The workbook.

Exceptions
System.ArgumentOutOfRangeException

The exception that is thrown when timeout is less than -1 or greater than Int32.MaxValue. Note that this upper bound is more restrictive than TimeSpan.MaxValue.

RegisterFormatProvider(IWorkbookFormatProvider)

Registers a format provider with the global manager, replacing any existing provider with the same name.

Declaration
public static void RegisterFormatProvider(IWorkbookFormatProvider provider)
Parameters
IWorkbookFormatProvider provider

The provider.

UnregisterFormatProvider(IWorkbookFormatProvider)

Removes the specified format provider from the global manager's registry.

Declaration
public static void UnregisterFormatProvider(IWorkbookFormatProvider provider)
Parameters
IWorkbookFormatProvider provider

The provider.

Getting Started
  • Getting Started
Support Resources
  • Documentation
Community
  • Forums
  • Blogs
  • Document Processing Feedback Portal

Copyright © 2018 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.