RealGrid2 API
Interface
DocumentTitle

DocumentTitle

When exporting a grid using the GridExportOptions model and GridBase.exportGrid(), set the title, subtitle, and footer of the Excel document. model for

Signature:

export interface DocumentTitle

Remarks

GridExportOptions.documentTitle, documentSubtitle, [documentTail](/refs/Interface /GridExportOptions#documenttail).

Properties

PropertyTypeDescription
heightnumberFull height of title
messagestringMessage (subject) to set Contents
spaceBottomnumberMargin below (row)
spaceTopnumbertop margin (row)
styleNamestringclassName to be applied to title
stylesstring | Partial<CSSStyleDeclaration>Styles to apply to the cell
visiblebooleanWhether to print to Excel

Properties Desc

height

Total height of title

Type - number

Remarks:

If the height is not specified (if it is -1), it is displayed as 1 row.


message

Message (subject) content to set

Type - string


spaceBottom

Margin below (row)

Type - number


spaceTop

Top margin (row)

Type - number


styleName

className to be applied to title

Type - string

Remarks:

If styleName is set, styles are not applied.


styles

Styles to apply to the cell

Type - string | Partial<CSSStyleDeclaration>

Example:

var styles1 = "color: blue;border: 1px solid red";
var styles2 = {color: "blue", border: "1px solid red"};
gridView.exportGrid({
    type: "excel",
    target: "local",
    documentTitle: {
        message: "Test Document",
        styles: styles1
    },
    documentTail: {
        message: "Test Tail",
        styles: styles2
    }
});

visible

Whether to print to Excel

Type - boolean