このイベントは列がエクスポートされるときに発生します。
this.exporterService.onColumnExport.subscribe((args: IColumnExportingEventArgs) => {
// イベントをハンドルするコードをここに入力します。
});
このイベントは、エクスポート処理が終了したときに発生します。
this.exporterService.onExportEnded.subscribe((args: ICsvExportEndedEventArgs) => {
// イベントをハンドルするコードをここに入力します。
});
このイベントは行がエクスポートされるときに発生します。
this.exporterService.onRowExport.subscribe((args: IRowExportingEventArgs) => {
// イベントをハンドルするコードをここに入力します。
});
IgxGrid コンポーネントのデータをエクスポートするメソッド。
this.exporterService.export(this.igxGridForExport, this.exportOptions);
任意の配列のデータをエクスポートするメソッド。
this.exporterService.exportData(this.arrayForExport, this.exportOptions);
Ignite UI for Angular Icon サービス - ヘルプ
Ignite UI for CSV Exporter サービスは、文字区切り値 (CSV) 形式で生データ (配列) または
IgxGridからデータをエクスポートします。 例:public localData = [ { Name: "Eric Ridley", Age: "26" }, { Name: "Alanis Brook", Age: "22" }, { Name: "Jonathan Morris", Age: "23" } ]; constructor(private csvExportService: IgxCsvExporterService) { } const opt: IgxCsvExporterOptions = new IgxCsvExporterOptions("FileName", CsvFileTypes.CSV); this.csvExportService.exportData(this.localData, opt);