Table of Contents

TAdvGridExcelExport Class

This component will export an existing TAdvStringGrid or TAdvWorkbook to Excel.

Syntax

Unit: UAdvGridExcelExport

TAdvGridExcelExport = class(TComponent);

Constructors

Name Description
Create Creates the component.

Destructors

Name Description
Destroy Frees all memory assigned to this component and releases the resources.

Methods

Properties

Name Description
AdvStringGrid The grid to export. If you set this property, then AdvGridWorkbook will be set to nil. In the same way, when you set AdvStringWorkbook, this property will be set to nil.
AdvGridWorkbook The workbook to export. If you set this property, then AdvStringGrid will be set to nil. In the same way, when you set AdvStringGrid, this property will be set to nil.
ExportOptions Settings that affect how the grid will be exported.
LocationOptions Settings that define where the grid will be exported in Excel.
DateFormat Default Excel format for the cells that contain dates. This is a global setting, you can control the format in individual cells with OnExportCell
TimeFormat Default Excel format for the cells that contain times. This is a global setting, you can control the format in individual cells with OnExportCell
ImageMargin Adds a margin around the cell for images or checkboxes. If you set this to 0 images will go exactly to the edges of the cell.
Version The version of this component.

Events

Name Description
OnExportCell Occurs before exporting every cell, and allows you to customize what is written in it.
OnProgress Provides a progress indication of how many cells have been exported.
OnExportComment Occurs before exporting a comment, and allows you to customize the size of the popup note that will appear in Excel.