Excel (XLSXW) Writer: Format Parameters
To access feature type parameters, click the gear iconon a feature type in the workspace to open theFeature Type Parameter Editor. To always display the editor in Workbench, you can select View > Windows > Parameter Editor.
All feature types share similar General Parameters. This includes Name and Writer Name. From here, you can also controlDynamic Properties.
These parameters apply only to a selected feature type, not to the entire writer.
Tip:如果此处列出的功能类型参数与Writer-Level参数冲突,则将忽略Writer参数,并将使用此功能类型参数。
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
- Drop sheet:所有现有纸张删除并重新创建工作表。(表单订单可能会改变。)
- Drop named range: Formatting and data in the extents of the existing named range are lost, but formatting in cells that exist outside the named range is unaffected. Original extents of the named range are lost. A new named range is created using the numbers specified in the Feature Type parametersNamed Range Start Column和Named Range Start Row.
This parameter is ignored if a template file is used, since the existing sheet/named range will always be replaced by the template sheet/named range. However, the writer feature type option to截断现有表格/命名范围在复制到目标文件之前应用于模板/命名范围。
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
If a template file or template sheet is specified as awriter parameter, the option to truncate the existing sheet or named range is applied to the template sheet before it is copied to the destination file. Inserted items such as charts and pictures are not deleted.
- 截断表:格式化等数据范围外部存在于单元格外的单元格颜色和列宽。
- Truncate named range: Data and formatting in the extents of the existing named range is lost, but formatting in cells outside this existing named range is unaffected.
The Feature Type parametersNamed Range Start Column和Named Range Start Roware ignored.
写入命名范围的数据使用原始的起始位置,并在开始列指定的偏移量并开始写入并开始行。
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
此参数指定要素类型的相对顺序。有效值是所有正整数(从1开始)。
具有最低相对级的表格将是工作簿中的第一张纸,在其之后具有更高阶的纸张。如果未指定值,则纸张将在具有指定的纸张顺序的所有工作表之后放置。如果两张纸具有相同的纸张订单值,则将根据其传入顺序排序两个。
如果表功能类型没有指定的顺序,but it contains a named range feature type which does, then the order on the named range will be used. If the sheet with no order contains two named ranges with different sheet orders, then one of those values will be selected arbitrarily. Therefore, to avoid ambiguity, it is always best to specify the order directly on the sheet feature type.
Example
如果您以形式编写7张[SheetName,Shterplation]
{(A, ),(B,9),(C, ),(D,4),(E,4),(F, ),(G,2)}
the sheets are written in the order
G,D/E,B,A/C/F
where the order of(A / C / F)和(D/E)are dependent on their incoming order to the writer.
使用要素类型粉丝将将模板要素类型的表单顺序传递给其所有扇动的功能类型。(见主题设置功能类型粉丝in FME Workbench help.)
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
此参数指定在插入数据时是否编写属性名称。
指定模板文件时,在插入数据时,此参数始终生效。
如果没有使用模板文件,则此参数才有效果,仅当正在创建纸张或命名范围或已在插入之前删除或截断。否则,将不会将属性名称添加到现有纸张或命名范围内。
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
此参数允许用户冻结第一个nrows, wheren是最后一行被冻结。例如,
- 1: the first row is frozen
- 2:前两排冻结
- 5: the first five rows are frozen
In Excel this feature is calledFreeze Panes, and it allows you to freeze a portion of the sheet so that certain rows like column headers remain visible while scrolling.
This option has no effect on named ranges.
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
Set to Yes to treat attribute names, such as A, B, or C as the column name in which to write the data. If set to No (the default), the columns will be written in the order on the schema.
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
If writing a Named Range, as determined by the feature type name, this parameter specifies the starting column in the sheet where the Named Range will be defined if it does not exist.
如果提供的命名范围名称已存在并且具有定义的范围,则忽略此参数。
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
如果编写命名范围,如通过功能类型名称确定,则此参数指定在不存在的情况下定义命名范围的工作表中的起始行。如果提供的命名范围名称已存在并且具有定义的范围,则忽略此参数。
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
此参数指定由要素类型名称标识的纸张中写入数据的起始列位置。此索引适用于基于单元的数据,但不适用于栅格或其他基于非小区的数据。
Row indexes are valid values between 1 and the maximum number of columns allowable in the sheet.
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
This parameter specifies a starting row location for writing data in the sheet identified by the feature type name. This index applies to cell-based data but does not apply to raster or other non-cell-based data.
Row indexes are valid values between 1 and the maximum number of rows allowable in the sheet.
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
指定是否在与此功能类型对应的当前工作表上启用纸张保护。板材保护是有用的,无法防止某人意外或故意更改,移动或删除重要数据。在Excel中,支持密码和非密码保护,但FME目前仅支持非密码保护。每列的单元格保护存在类似的设置;但是,目前无法保护整个工作簿以防止纸张的添加,拆卸或重新排列。此设置不适用于命名范围。
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
You can embed a map or raster image from another source directly into a spreadsheet. This parameter determines which raster format will be used for rasters written to the workbook. There are three supported options
- PNG
- JPEG
- BMP
向编写器发送栅格功能时,您可以添加一些属性以修改结果。
Attribute Name | Description |
---|---|
xlsx_row_id. | 确定将放置图像顶部的行。图片将与行的顶部对齐。 只有正整数值都有效。 如果未指定,则此值将默认为1,对应于第1行。 |
xlsx_col_id. | Determines the column on which the left of the picture will be placed. The picture will align on the left side of the column. Only positive integer values or the Microsoft Excel Column letter designations (A,B,..,XFD) are valid. If not specified, this value will default to 1, which corresponds to column A. |
xlsx_raster_scale_factor | 允许栅格缩放为一个因素。这可以是大于0.0的任何正数值。 If not specified, the raster will be written out using thexlsx_raster_height.和xlsx_raster_width. 如果指定,xlsx_raster_height.和xlsx_raster_width将被忽略。 例如,一个比例因子为2.0的两倍width and height of the raster. If the image is larger than the height or width of a cell, the image will cover multiple cells. The cell height will not change. |
xlsx_raster_height. | Sets the raster height to the specified number of pixels. Only positive integer value greater than 0 are valid. Note:Ifxlsx_raster_scale_factoris specified, this value will be ignored. If this is used, you should also specifyxlsx_raster_width. If neither is specified, the raster will default to its actual size. If the image is larger than the height or width of a cell, the image will cover multiple cells. The cell height will not change. |
xlsx_raster_width | Sets the raster width to the specified number of pixels. Only positive integer value greater than 0 are valid. Note:Ifxlsx_raster_scale_factoris specified, this value will be ignored. If this is used, you should also specifyxlsx_raster_height.. If neither is specified, the raster will default to its actual size. If the image is larger than the height or width of a cell, the image will cover multiple cells. The cell height will not change. |
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
The writer mode can be specified on the feature type or on individual features.
At the feature type level, the writer mode is specified by this parameter. It may be superseded on individual features by thefme_db_operationformat attribute.
Valid feature type writer modes are listed below:
Mode | Description |
---|---|
Insert | Appends features to the end of the sheet, or writes them to an exact row and/or column. Any data that already exists in that location will be overwritten. If there is a row value specified for theRow Number Attribute,将使用该行。 |
更新 | 导致与指定的特征值对应的行Row Number Attributeto have its data changed to the values on the incoming feature. 如果在传入功能上缺少属性,则不会覆盖现有的单元格值。 |
Delete | 删除对应于指定的特征值对应的行中的值Row Number Attribute. Only a number of columns equal to the amount of columns on the incoming feature will have their data and formatting removed. |
![Closed](http://www.baooytra.com/docs/fme/2017.0/html/FME_Desktop_Documentation/FME_ReadersWriters/xlsx/../Skins/Default/Stylesheets/Images/transparent.gif)
该撰写器允许您指定输入属性以包含用于每次特征更新和删除操作的行号标识符的值。
The default row number attribute is thexlsx_row_id.由Excel Reader生成的属性来保存行号,但它可以更改为任何属性。
Note:与可能不排序行ID的数据库不同,行号标识符对应于从纸张顶部(类似于CSV文件中的行号)的行数。