New to Telerik Document ProcessingStart a free 30-day trial

General Information

Updated on Jun 16, 2026

The RadSpreadProcessing document model allows you to open and save files of different formats. The following sections provide more details on the supported formats, available format providers, the additional package references each provider requires, and the Format Providers Manager.

Supported Formats

The following table lists the supported formats:

FormatDescription
XlsxRich text format that exports the whole content of a workbook: worksheets, formula values, formatting, hyperlinks, and more.
XlsRich text format that exports the content of a workbook: worksheets, formula values, formatting, hyperlinks, and more. Supported in older applications. This format is not supported in Silverlight.
XlsmRich text format that exports all that is included in the Xlsx format with the addition of macro instructions.
Pdf (export only)Fixed format that preserves the content of a workbook in a manner independent from software or hardware.
Csv (comma separated)Plain text format that saves the content of the cell in the active worksheet. The format strips all formatting and keeps only the result values of cells. These values are separated by a culture-dependent delimiter.
Txt (tab delimited)Plain text format that preserves only the content of the cells in the active worksheet. The format does not save any formatting and keeps only the result values of the cells. These values are delimited through tabs.
Json (export only)Structured text format that serializes worksheet data and metadata (values, number formats, named ranges, charts, active sheet info) to JSON. Styling is not preserved fully as in XLSX.
DataTableAllows you to convert a DataTable from your database to a spreadsheet and vice versa.

In Q4 2024 Telerik Document Processing Libraries introduced a new timeout mechanism for importing and exporting documents. The Import and Export methods of all FormatProviders have a mandatory TimeSpan? timeout parameter after which the operation is cancelled.

Format Providers

The document model exposes separate format providers that work with each of the formats listed previously:

Some FormatProviders require additional package references. Check them out in the Additional Package References section.

Import and Export Methods

All of the listed providers implement the IWorkbookFormatProvider and IBinaryWorkbookFormatProvider interfaces and share a common API that enables import and export of files. To conform to the interfaces, each of the providers implements two methods that turn a Stream or byte[] into a workbook and save the contents of the workbook into a Stream or byte[]. In the IWorkbookFormatProvider interface methods and IBinaryWorkbookFormatProvider interface methods sections you can see the interface declarations and an example usage of the Import and Export methods.

IWorkbookFormatProvider Interface Methods

C#
public interface IWorkbookFormatProvider
{
    string Name { get; }
    string FilesDescription { get; }
    IEnumerable<string> SupportedExtensions { get; }
    bool CanImport { get; }
    bool CanExport { get; }

    //Import and Export methods with Stream support
    void Export(Workbook workbook, Stream output, TimeSpan? timeout = null);
    Workbook Import(Stream input, TimeSpan? timeout = null);
}

Example: Use the Import() and Export() Methods with Stream

C#
string path = "MyWorkbook.xlsx";
Telerik.Windows.Documents.Spreadsheet.Model.Workbook workbook;
var formatProvider = new Telerik.Windows.Documents.Spreadsheet.FormatProviders.OpenXml.Xlsx.XlsxFormatProvider();

//Import
using (Stream input = new FileStream(path, FileMode.Open))
{
    workbook = formatProvider.Import(input, TimeSpan.FromSeconds(10));
}

//Export
using (Stream output = new FileStream(path, FileMode.Create))
{
    formatProvider.Export(workbook, output, TimeSpan.FromSeconds(10));
}

IBinaryWorkbookFormatProvider Interface Methods

C#
public interface IBinaryWorkbookFormatProvider : IWorkbookFormatProvider
{
    //Overloading IWorkbookFormatProvider's Import and Export methods to support byte[]
    byte[] Export(Workbook workbook);
    Workbook Import(byte[] input);
}

Example: Use the Import() and Export() Methods with byte[] Array

C#
var path = "MyWorkbook.xlsx";
Telerik.Windows.Documents.Spreadsheet.Model.Workbook workbook;
var formatProvider = new Telerik.Windows.Documents.Spreadsheet.FormatProviders.OpenXml.Xlsx.XlsxFormatProvider();

//Import
byte[] fileAsByteArray = File.ReadAllBytes(path);
workbook = formatProvider.Import(fileAsByteArray, TimeSpan.FromSeconds(10));

//Export
byte[] workbookAsByteArray = formatProvider.Export(workbook, TimeSpan.FromSeconds(10));

For more examples of importing and exporting workbooks, check out the Import/Load and Export/Save RadSpreadProcessing Workbook knowledge base article.

Additional Package References

Unlike the CsvFormatProvider, TxtFormatProvider, and DataTableFormatProvider classes, the other RadSpreadProcessing format providers require references to additional packages:

Format ProviderRequired Package
XlsxFormatProvider and XlsmFormatProviderTelerik.Windows.Documents.Spreadsheet.FormatProviders.OpenXml
PdfFormatProvider (export only)Telerik.Windows.Documents.Spreadsheet.FormatProviders.Pdf
XlsFormatProviderTelerik.Windows.Documents.Spreadsheet.FormatProviders.Xls
JsonFormatProvider (export only)Telerik.Windows.Documents.Spreadsheet.FormatProviders.Json

*Starting with Q2 2025 the Zip Library will no longer be used as an internal dependency in the rest of the Document Processing Libraries - PdfProcessing, WordsProcessing, SpreadProcessing, SpreadStreamProcessing. It will be replaced by the System.IO.Compression. The Telerik Zip Library will continue to ship as a standalone library so clients can still use it separately.

Format Providers Manager

The document model of RadSpreadProcessing also contains a WorkbookFormatProvidersManager class, which exposes a whole set of useful static methods. The manager also allows you to specify a set of format providers you want to use. Then you can import and export a file and let the manager choose the appropriate format provider. You only need to specify the extension of the file that you open or save.

More information on the Format Providers Manager and the WorkbookFormatProvidersManager class can be found in the dedicated Format Providers Manager article.

See Also