Export Technical Reference
Export State
ExportState
Export section of Adaptable State, including Initial State.
Reports are reports you define. AdapTable also provides the system reports 'All Data', 'Current Layout' and 'Selected Data'. CurrentReport and CurrentFormat are the report and format selected in the Export toolbar. ReportSchedules run a report on a Schedule.
Selected Report Format - in Export Toolbar & Tool Panel
Selected Report Type - in Export Toolbar & Tool Panel
Scheduled Exports for System and Custom Reports
Report
Report
A report you define.
ReportColumnScope chooses the columns. Set Scope only when that is 'ScopeColumns'. ReportRowScope chooses the rows. Set Expression only when that is 'ExpressionRows'. The system reports are separate from this list.
string
AdapTableQL boolean expression selecting the rows to export; only required if ReportRowScope is 'ExpressionRows'
Name of the Report as displayed in the Export toolbar and tool panel
Columns to display: AllColumns, VisibleColumns, SelectedColumns, ScopeColumns
Rows to export: AllRows, VisibleRows, SelectedRows, ExpressionRows
Columns Scope; only required if ReportColumnScope is 'ScopeColumns'
boolean
Sets Entity to ReadOnly (overwriting a Strategy Entitlement of 'Full')
ReportColumnScope is a ReportColumnScope:
| Value |
|---|
'AllColumns' |
'VisibleColumns' |
'ScopeColumns' |
'SelectedColumns' |
ReportRowScope is a ReportRowScope:
| Value |
|---|
'AllRows' |
'VisibleRows' |
'ExpressionRows' |
'SelectedRows' |
Scope is a Column Scope:
ColumnScope
Which columns an object applies to. Set exactly one shape.
true
Matches every column. All must be true.
('text' | 'number' | 'boolean' | 'date' | 'textArray' | 'numberArray')[]
Data types to match, for example ['number'] or ['text', 'textArray']. Object, tuple and unknown columns are not scope data types. Name those columns with ColumnIds.
string[]
Column ids to match. These are AG Grid colId values.
string[]
AG Grid column type names, the strings set on colDef.type.
Schedules
ReportSchedule
A timed export for a report — when to run, format and destination
Destination of Report to run on Schedule
string
Unique display name for this scheduled report
Format of Report to run on Schedule
Name of Report to export
boolean
Sets Entity to ReadOnly (overwriting a Strategy Entitlement of 'Full')
boolean
Suspends (i.e. turns off) an Adaptable Object
Schedule
When a scheduled alert or export runs.
IsOneOff: true runs once at RunAt (an ISO date-time). IsOneOff: false repeats on CronExpression, a 5-field cron (minute, hour, day of month, month, day of week). Weekdays in that cron are 0–6 with Sunday as 0; 1-5 is Monday to Friday.
string
Standard 5-field cron (minute hour day-of-month month day-of-week); e.g. weekdays at 09:30 → 30 9 * * 1-5
boolean
true runs once, at RunAt. false repeats on CronExpression.
string
ISO datetime for a one-off run (local time); set when IsOneOff is true
Export Options
ExportOptions
Options regarding Exporting data from AdapTable
string | ((csvSeparatorContext:BaseExportContext) => string)
Separator for CSV exports
','
CustomDestination[] | ((context:CustomDestinationsContext) =>CustomDestination[])
User-provided Report Destinations (in addition to those shipped in AdapTable)
string | ((excelSheetNameContext:BaseExportContext) => string)
Provides a custom name for the Excel sheet when exporting to Excel
'Sheet 1'
DataFormatType|DataFormatDataType| ((context:ExportDataFormatContext<TData>) =>DataFormatType)
Sets 'rawValue' or 'formattedValue' as Data format in Reports; can be set for whole grid, per Data Type, or per Column (via a function)
rawValue
string | ((context:ExportDateFormatContext<TData>) => string)
Optional custom format for Date columns when exporting
undefined
(context:GetDetailRowsContext<TData>) => CsvDetailRow[] | ExcelDetailRow[] | undefined
Function to provide the Detail Rows when exporting in Master-Detail grids. This function will be invoked for each master row node.
(context:AdaptableColumnContext) => boolean
Whether a Column is included in System Reports and available in UI for selection
true
(processExportContext:ProcessExportContext) => Promise<ExportResultData | boolean>
Provides custom handling of the Export process before the default export is executed.
(reportFileNameContext:ReportFileNameContext) => string
Provide a bespoke file name for the Report
boolean | ((skipColumnHeadersContext:BaseExportContext) => boolean)
Whether to exclude Column Headers from the exported data
false
SystemExportDestination[] | ((context:SystemExportDestinationsContext) =>SystemExportDestination[])
Export destinations to use; leave unset for all, empty array for none
'Download', 'Clipboard'
SystemReportFormat[] | ((context:SystemReportFormatsContext) =>SystemReportFormat[])
System Report Formats to use; leave unset for all, empty array for none
'Excel', 'VisualExcel', 'CSV', 'JSON'
SystemReportName[] | ((context:SystemReportNamesContext) =>SystemReportName[])
System Reports to use; leave unset for all, empty array for none
'All Data', 'Current Layout', 'Selected Data',
systemReportFormats values are Excel, VisualExcel, CSV, and JSON.
systemReportNames values are All Data, Current Layout, and Selected Data.
systemExportDestinations values are Download and Clipboard.
exportDataFormat is 'rawValue' or 'formattedValue'.
customDestinations entries are a CustomDestination:
CustomDestination
Defines a custom Export destination
Optional Adaptable Form; if provided, it must include Buttons that will execute the Export
string
Name of Custom Destination (mandatory)
(reportContext:ReportContext) => void
Optional Function invoked when Export is applied (used if no form is supplied)
form on a custom destination is an AdaptableForm:
AdaptableForm
Expand
Defines the form. fields is a list of fields, rows of fields, or field groups. buttons are the form buttons. layout is rows (the default) or inline.
AdaptableForm
Defines a form which appears dynamically; used by Alerts, Export Custom Destinations and Dashboard Custom Toolbars.
string
Additional information to appear in the Form
Collection of Dynamic Fields and Field Groups to display.
Items can be:
- a single (rendered on its own row in the
default rows layout, or as one cell in the inline layout),
- an array of (rendered side-by-side on the
same row in the rows layout), or
- an (a labelled section that
visually groups related fields).
How the form's fields are arranged on screen.
- rows (default): each field on its own row, label on the left and
input on the right. Suitable for popups / wizards.
- inline: fields are placed side-by-side on a single horizontal line,
with the label rendered immediately before its input. Designed for
compact contexts such as Dashboard Custom Toolbars where vertical
real-estate is scarce.
'rows'
(formData: TData, context: T) => void
Optional form-level submit hook.
Fired when the user presses Enter while focus is inside any field
input AND the form is currently valid. The full formData is passed
through, typed as TData if you've supplied a custom shape.
Use this as an ergonomic shortcut to avoid wiring an explicit "Submit"
button - or in addition to one, so power users can press Enter to
commit. If the form is invalid the hook is not invoked.
string
Title to appear in the Form
Each field is an AdaptableFormField:
AdaptableFormField
Defines a Field that appears in an Adaptable Form
boolean
For single select fields only. When the user clears the combobox,
whether to restore instead of leaving the field empty.
Defaults to true when defaultValue is set, otherwise false.
Set to false when an empty selection is a distinct state from the default.
string | boolean | number | Array<string | number | boolean>
Field Default Value - can be of type string, boolean, number, or forselect fields with multi: true an array of those.
For single select fields, this is also the value restored when the user
clears the combobox (unless is false).
boolean | ((formData:AdaptableFormData, context:BaseContext) => boolean)
Disable the field's input. Either a boolean or a function evaluated
against the current form data. Disabled fields render but the user
cannot edit them.
Field Type - dictates which UI control is rendered
string
Inline help text rendered immediately below the field's input. Useful
for short explanations such as "format: YYYY-MM-DD" or "min 3 chars".
string
Label to display in the Field
number | string
Maximum allowed value. For number and slider: the highest accepted
number. For date, time and datetime: the latest allowed value in
ISO format.
number
Maximum length for text and textarea fields.
number | string
Minimum allowed value. For number and slider: the lowest accepted
number. For date, time and datetime: the earliest allowed value
in ISO format (YYYY-MM-DD / HH:mm / YYYY-MM-DDTHH:mm).
number
Minimum length for text and textarea fields.
boolean
For select fields only. When true the field renders as a
multi-select combobox; the field's value is an array of selectedoption.values rather than a single value.
false
string
Name of the Field
(value: any, context:BaseContext) => void
Optional callback invoked whenever value of this field changes
AdaptableFormFieldOption[] | ((formData:AdaptableFormData, context:BaseContext) =>AdaptableFormFieldOption[] | Promise<AdaptableFormFieldOption[]>)
Items to populate the select and radio fieldTypes.
Either a static array, or a function that derives the options from the
current form data and Adaptable context. The function form may return
a Promise for asynchronously-loaded options - the form will render the
field with no items until the promise resolves.
string
Regular expression that the value of a text field must match.
string
Placeholder text shown inside text, textarea, number, date,time and datetime inputs when empty. For select fields it is
rendered as the empty-state label when no value is selected.
When omitted on a select field with a , the label of
the matching options entry is used as the empty-state label.
(params:AdaptableFormFieldRenderParams) => React.ReactNode
For custom fields only. Renders an arbitrary React node as the
field's input. Receives the current value, a setValue setter
(controlled), the current form data, the Adaptable context and the
resolved disabled state.
Use this as an escape hatch when none of the built-in fieldTypes
fit - e.g. to render a star-rating widget, a tag editor or any
bespoke control.
boolean
If true the field is treated as required. An empty value ('',null, undefined, or unchecked checkbox) will produce a validation
error.
number
Stepping interval for number, slider, time and datetime
fields.
string
Tooltip shown when hovering the field's label.
(value: any, formData:AdaptableFormData, context:BaseContext) => string | null | undefined
Custom field-level validation. Return an error message string to mark
the field invalid, or null/undefined if the value is valid.
Custom validation runs after built-in checks (required, min,max, pattern, etc.) - the first failing check wins.
fieldType is an AdaptableFormFieldType:
| Value |
|---|
'text' |
'textarea' |
'select' |
'radio' |
'date' |
'time' |
'datetime' |
'number' |
'slider' |
'color' |
'checkbox' |
'textOutput' |
'custom' |
Select and radio options are AdaptableFormFieldOption objects:
AdaptableFormFieldOption
One choice in a select or radio form field.
layout is an AdaptableFormLayout:
| Value |
|---|
'rows' |
'inline' |
buttons are AdaptableButton objects:
AdaptableButton
A button on a form, alert or toolbar.
label is the text. onClick runs when it is clicked and receives the button and the form or event context. buttonStyle and icon are optional. disabled and hidden are functions that return whether the button is disabled or hidden.
(button:AdaptableButton<CONTEXT_TYPE>, context: CONTEXT_TYPE) => boolean
Function that disables / enables the button based on its evaluation result
AdaptableIcon| ((button:AdaptableButton<CONTEXT_TYPE>, context: CONTEXT_TYPE) =>AdaptableIcon)
Icon for Button - can be object or function that provides a AdaptableIcon object
string | ((button:AdaptableButton<CONTEXT_TYPE>, context: CONTEXT_TYPE) => string)
Label for Button - can be string or function that provides string
(button:AdaptableButton<CONTEXT_TYPE>, context: CONTEXT_TYPE) => void
Function to invoke when button is clicked
string | ((button:AdaptableButton<CONTEXT_TYPE>, context: CONTEXT_TYPE) => string)
Tooltip for Button - can be string or function that provides string
buttonStyle is a ButtonStyle:
ButtonStyle
Appearance of an AdapTable button.
variant is 'text', 'outlined' (the default) or 'raised'. tone is the colour: 'neutral' (the default), 'success', 'error', 'warning', 'info', 'accent' or 'none'. className adds a CSS class.
string
CSS Classname to use for the Button
'success' | 'error' | 'neutral' | 'none' | 'warning' | 'info' | 'accent'
Button's Tone - values: 'success', 'error', 'neutral', 'none', 'warning', 'info', 'accent'
'neutral'
'text' | 'outlined' | 'raised'
How Button appears - values: 'text', 'outlined', 'raised'
'outlined'
getDetailRows receives a GetDetailRowsContext:
GetDetailRowsContext
Context provided to ExportOptions.getDetailRows() callback used when exporting Detail Rows
Column of Master Row Node
(cellContent: any) => CsvCell
Factory function to create a CSV Cell
(cellContent: any, cellType: ExcelDataType) => ExcelCell
Factory function to create an Excel Cell
(cellContent: any) => ExcelCell
Factory function to create an Header Cell (either CSV or Excel)
boolean
Whether the Master Row Node is expanded
TData
Data of Master Row Node
IRowNode<TData>
Master Row Node
Custom application Context provided in AdaptableOptions.adaptableContext
processExport receives a ProcessExportContext:
ProcessExportContext
Context used by the processExport function
(reportData:ReportData) => string
Converts the Report Data to CSV format
(reportData:ReportData) => Blob
Converts the Report Data to Excel format
() =>ReportColumn[]
Returns Columns to export based on Report's ReportColumnScope
Custom application Context provided in AdaptableOptions.adaptableContext
reportFilename receives a ReportFilenameContext:
ReportFileNameContext
Context used for providing a custom filename for a Report
string
Default File Name to use
Custom application Context provided in AdaptableOptions.adaptableContext
Export API
ExportApi
Reports and scheduled exports: which report and format are selected, where a report can be sent, and running or scheduling an export.
void
Adds a schedule that runs a report on a cron expression or at one time.
void
Runs a scheduled export now and records that the job ran.
boolean
Whether this instance can export to CSV.
boolean
Whether this instance can export to Excel.
void
Sets the Report Format to null
void
Sets the Report to null
void
Removes a scheduled report.
void
Replaces a scheduled report already in state.
void
Ensures every scheduled report has a unique Uuid (legacy state may omit them).
Promise<void>
Exports the Report with the given Name and Format to the given Destination
Scheduled reports that are not suspended.
Retrieves the available export destinations
Every report format that can be selected, system and custom.
Report[]
Retrieves all available Reports - System and User-created Reports
Custom destinations supplied in Export Options.
System destinations that Export Options allow.
System report formats that Export Options allow.
System report names that Export Options allow.
Report | undefined
Retrieves currently selected Report in Adaptable State
ReportFormatType | undefined
Format currently selected for export.
ReportNameType | undefined
Name of the report currently selected for export.
Report[]
Reports created by the user. System reports are not included.
SystemExportDestination|CustomDestination | undefined
Retrieves Destination with the given name
AdaptableForm<ExportFormContext> | undefined
The form a custom destination shows before export.
The Export section of Adaptable State.
Retrieves Report by Id
Report | undefined
Retrieves Report with the given name
Promise<ExportResultData>
Gets the data for the Report with the given Name in the given Format
ReportSchedule | undefined
A scheduled report looked up by its id.
Every scheduled report, including suspended ones.
Retrieves the Export Destinations that are supported for the given Report Format
boolean
Whether a column is included in an export.
boolean
Whether the destination is one AdapTable provides (Download or Clipboard) rather than a custom destination.
void
Open Settings Panel with Export section selected
void
Selects the report format used by the next export.
void
Selects the Report in the Adaptable State
void
Stops a schedule from running until it is unsuspended.
void
Makes a suspended schedule run again.
Updates an existing report
Report[]
Replaces the given custom reports in Export State.
Report Schedule Ran Event
The Report Schedule Ran Event is published whenever any report runs on a Schedule.
The ReportScheduleRanInfo provides full information on the Report and the Schedule:
ReportScheduleRanInfo
Payload of the ReportScheduleRan event.
Fires when a scheduled report runs.
Extends , so adaptableApi is included.
string
When this run started, as an ISO datetime (new Date().toISOString()).
The schedule that just ran.
Custom application Context provided in AdaptableOptions.adaptableContext
Live Data Changed Event
The Live Data Changed Event is published when a live report for the ipushpull or OpenFin plugins connects, disconnects, sends a snapshot, or starts, stops or updates.
The payload is a LiveDataChangedInfo object:
LiveDataChangedInfo
Payload of the LiveDataChanged event.
Fires for the ipushpull and OpenFin live-report plugins: when the destination connects or disconnects, a snapshot is sent, or live data starts, stops or is pushed.
Extends , so adaptableApi is included.
'Connected' | 'Disconnected' | 'SnapshotSent' | 'LiveDataStarted' | 'LiveDataStopped' | 'LiveDataUpdated'
What happened:
- Connected — the destination session started. liveReport is omitted.
- Disconnected — the destination session ended. liveReport is omitted.
- SnapshotSent — a one-off snapshot was sent. liveReport is omitted.
- LiveDataStarted — a report started streaming. liveReport is that report.
- LiveDataStopped — streaming stopped. liveReport is the report that was live.
- LiveDataUpdated — a new snapshot of the live report was pushed. liveReport is that report.
any
The ipushpull or OpenFin report this change is about.
Set for LiveDataStarted, LiveDataStopped and LiveDataUpdated. Omitted for Connected, Disconnected and SnapshotSent.
This is the plugin report (an ipushpull report or an OpenFin report), not a .
'OpenFin' | 'ipushpull'
Destination this change belongs to: OpenFin or ipushpull.
Custom application Context provided in AdaptableOptions.adaptableContext
Live Report
The Live Report defines which Adaptable Reports are 'Live' (i.e. they will update the destination as the data in Adaptable ticks or changes):
Note
When Adaptable creates a Live Report it will take care of updating the destination as the data in the Report changes (based on the throttle time it is given).
LiveReport
Defines which Adaptable Reports are 'Live' (i.e. will update the destination as data in Adaptable ticks or changes)
string
For OpenFin this is the workbook name; for iPushpull the page name
'OpenfinExcel' | 'ipushpull'
Where the live data is being sent.OpenfinExcel is the OpenFin value on this object. uses OpenFin for the same destination.