|
FlexCel Studio for VCL/LCL
|
Autofits a range of rows so they adapt their height to show all the text inside. Note that due to GDI+ / GDI incompatibilities, the height calculated by FlexCel will not be exactly the same than the one calculated by Excel. So when you open this workbook in Excel, Excel will re calculate the row heights to what it believe is best. You can change this behaviour specifying keepHeightAutomatic = false.
procedure AutofitRow(const row1: integer; const row2: integer; const AutofitNotAutofittingRows: Boolean; const keepHeightAutomatic: Boolean; const adjustment: extended); overload;
__fastcall AutofitRow(const int row1, const int row2, const Boolean AutofitNotAutofittingRows, const Boolean keepHeightAutomatic, const extended adjustment);
|
Parameters |
Description |
|
const row1: integer |
First row to autofit. |
|
const row2: integer |
Last row to autofit. |
|
const AutofitNotAutofittingRows: Boolean |
When you are autofitting a range of rows, some rows might not be set to Autofit in Excel. When this parameter is true, those rows will be autofitted anyway. |
|
const keepHeightAutomatic: Boolean |
If true, rows will be still autoheight when you open the file in Excel, so Excel will recalculate the values, probably changing the page breaks. If you set it to false, rows will be fixed in size, and when you open it on Excel they will remain so. |
|
const adjustment: extended |
You will normally want to set this parameter to 1, which means that autofit will be made with standard measurements. If you set it to for example 1.1, then rows will be adjusted to 110% percent of what their calculated height was. Use this parameter to fine-tune autofiting, if for example rows are too small when opening the file in Excel. |
|
Copyright (c) 2002-2008 TMS Software. All rights reserved.
|
|
What do you think about this topic? Send feedback!
|