Table of Contents

TXlsFile.CopyColFormats Method

Copies the column definitions, that is formats, widths, hidden/visible, etc from one workbook or sheet to another.

Syntax

Unit: FlexCel.XlsAdapter

procedure TXlsFile.CopyColFormats(const sourceWorkbook: TExcelFile; const sourceSheet: Integer; const sourceCol: Integer; const destCol: Integer; const colCount: Integer); override;

Parameters

<-> Parameter Type Description
const sourceWorkbook TExcelFile The workbook from where the column formats will be copied. If you set this to null, the column formats will be copied from the same file.
const sourceSheet Integer Sheet in the source workbook from where we will copy the column formats.
const sourceCol Integer First column format to copy
const destCol Integer First column where the format will be copied.
const colCount Integer Number of columns to copy.

See also