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

Use Spreadsheet Documents in Business Objects

  • 2 minutes to read

This topic describes how to use the SpreadsheetPropertyEditor and ASPxSpreadsheetPropertyEditor to display byte array properties in WinForms and ASP.NET applications. The following images demonstrate these Property Editors assigned to the Document.Data property:

Assign the Spreadsheet Property Editor to a Business Class’ Property

In Code

Decorate a business class’ property with the EditorAliasAttribute and pass the SpreadsheetPropertyEditor value as the attribute’s parameter:

using DevExpress.ExpressApp.Editors;
using DevExpress.Persistent.Base;
using DevExpress.Persistent.BaseImpl;
// ...
private byte[] data;
[EditorAlias(EditorAliases.SpreadsheetPropertyEditor)] 
public byte[] Data { 
    get { return data; }
    set { SetPropertyValue(nameof(Data), ref data, value); }
}

In the Model Editor

Navigate to the Views | <DetailView> | Items | <PropertyEditor> node and set the PropertyEditorType property to DevExpress.ExpressApp.Office.Win.SpreadsheetPropertyEditor or DevExpress.ExpressApp.Office.Web.ASPxSpreadsheetPropertyEditor.

Edit the Document in a Separate Window

Use the Show in popup context menu command to open the document in a new modal window.

In ASP.NET applications, you can edit the document in full-screen mode.

See Also