Task Office - Excel - Convert

The Excel - Convert Task converts Excel workbooks to another Excel format, or writes worksheet cells to a text file. The File filter tab selects the workbooks to convert.
The Main settings, Flow, On error, Conditions and TimeOut tabs are the same for every Task; see Job - Tasks.
The Task settings are on the Excel - Convert tab, which has the sub tabs File filter and Convert settings, and on the Output tab of the Task window.
File filter tab
The File filter tab selects the workbooks to convert; see Task - File filter. The Credential on its Location tab is used both to read the workbooks and to write the converted files.
When no file matches the filter, the Task raises a "file not found" error, which you can handle on the On error tab (see Task - On Error).
Convert settings tab

-
Convert to..: The format to convert to: "TextFile" (the default), "Excel2007", "Excel2007MacroEnabled", "Excel2007MacroEnabledTemplate", "Excel2007Template", "Excel97To2003" or "Excel97To2003Template"
When a workbook already has the selected Excel format, the Task does not convert or save it.
-
Convert visible values: With "TextFile" only, writes the text that each cell shows in Excel instead of the stored cell value
When it is cleared, date cells are written with their date format and other cells with their stored value.
The Worksheet and Cell ranges groups apply only to "TextFile".
Worksheet
-
Use first worksheet: Converts the first worksheet of each workbook
-
Use specific worksheet: Converts the worksheet with the name you enter or select
Click Get to choose a workbook and list its worksheets. The name can contain Variables.
-
Password: The password that opens protected workbooks, used only for a workbook that is encrypted
Cell ranges
-
Cells by position: Converts the columns from Column start to Column end (column numbers, starting at "1") of every row
Reading stops after more than 10 rows in a row that have no data in those columns.
-
Cells by position range: Converts the rows from Row start to Row end and the columns from Column start to Column end (numbers, starting at "1")
-
Cell by reference range (i.e. B2): Converts the range from Cell reference start to Cell reference end, for example "A1" to "D20"
Rows with no data in the selected columns are left out of the text file. The text file is written in UTF-8, with the field separator, text qualifier and line break set on the Output tab.
Save to..
-
Same file: Writes the result into the source file
In the current version, the source file is opened read-only, so saving fails with an error and the source file is not changed. Use one of the other options.
-
Same folder but change extension: Saves to the source folder with the source file name and the extension of the selected format: ".txt", ".xlsx", ".xlsm", ".xltm", ".xltx", ".xls" or ".xlt"
-
Same folder but use file mask: Saves to the source folder with the name from File mask
-
Different folder and use file mask: Saves to Folder with the name from File mask
-
Folder: The destination folder, used only with Different folder and use file mask
-
File mask: The name of the saved file, "*" by default, which keeps the source name
Folder and File mask can contain Variables.
An existing file with the destination name is overwritten without warning. With Same folder but use file mask and the default File mask *, or with Different folder and use file mask and the source folder as Folder, the converted file gets the name of the source file and replaces the source workbook. Set a File mask such as *.txt, or use Same folder but change extension.
The Task creates the destination file, or empties an existing one, before it converts the workbook. When a workbook already has the selected Excel format, the Task skips it and leaves that destination file empty. If the destination is the source file itself, for example Same folder but change extension to the format the workbook already has, the source workbook is left empty, and the Task reports success.
Output tab
These settings apply only to "TextFile":
- Field separator: The character between fields: "Colon", "Semicolon", "Comma", "Pipe", "Tab" (the default), "Blankspace", "Tilde", "None", "Equal", "Cr", "CrLF" or "Lf"
- Text qualifier: None (the default),
"or', written around every field - Line break: The character between rows: "Cr", "CrLf" (the default), "Lf", "Comma", "SemiColon", "Pipe", "Tab" or "NoLineBreak"
Include column names has no effect for this Task.
Output and errors
The output of the Task is the path of each file it saved. When several files are saved, the paths follow each other without a separator. A workbook that cannot be opened or saved stops the Task with an error.