span8
span4
span8
span4
This article applies toFME 2013 SP1 (build 13450) and earlier only.In FME 2013 SP2,the Excel ADO based reader & writer (XLS_ADO) was deprecated and replaced by the a new Excel reader & writer based on libXL libraries (XLSX and XLSX2).For details on the current Excel reader/writer visit theGetting Started with ExcelTutorial
The Excel writer (FME 2013 SP1(build 13450) and earlier only)does not have a setting which allows you to delete an existing file prior to writing to the file.This can be a problem as features are inserted into an existing file possibly resulting in duplicate records.The only way to get around this is to delete the file first either via a Startup script or by using a DOS command in a batch file.
To use a TCL startup script enter the string
if { [file exists $FME_MacroValues(DestDataset_XLS_ADO_3)] == 1 } { puts [concat Deleting $FME_MacroValues(DestDataset_XLS_ADO_3)] file delete -force $FME_MacroValues(DestDataset_XLS_ADO_3) } else { puts [concat $FME_MacroValues(DestDataset_XLS_ADO_3) does not exist] }
To use a Python startup script enter the string - which will check if the file actually exists and delete it if it does.
Newer versions of FME have a parameter that you can set to choose whether to delete the existing file or add to it.
© 2019 亚搏在线Safe Software Inc |法律