API REFERENCE

exportDataAsExcel

Downloads an XLSX file using the specified sheet name, columns, and selection conditions.

What does this API do?

Downloads an XLSX file using the specified sheet name, columns, and selection conditions.

API for Pro features: Built-in Excel export

Exact input and result types

typescript
exportDataAsExcel(options?: {
      fileName?: string;
      sheetName?: string;
      onlySelected?: boolean;
      columnKeys?: readonly string[];
      skipHeaders?: boolean;
    }): Promise<void>
ArgumentsRequiredType
optionsOptional{ fileName?: string; sheetName?: string; onlySelected?: boolean; columnKeys?: readonly string[]; skipHeaders?: boolean; }

The return type is Promise<void>.

Usage flow

After registering and initializing the Grid element, call grid.exportDataAsExcel(…). Read the return value with await. For methods returning a boolean or report, inspect the result before continuing.

Feature explanations and examples