Filelist input - Support for tab-separated and CSV list formats

Discussions on NConvert - the command line tool for image conversion and manipulation

Moderators: XnTriq, helmut, xnview

cday
XnThusiast
Posts: 4238
Joined: Sun Apr 29, 2012 9:45 am
Location: Cheltenham, U.K.

Filelist input - Support for tab-separated and CSV list formats

Post by cday »

The filelist file input option -l currently only supports input from a filelist with each file on a separate line.

Could support please be added for tab-separated and CSV format filelists, the output format options available in MS Excel, which are probably more widely supported formats.


Support for either or both of the above options, and also the pending fix for the filename issue in this thread, would be required for the solution proposed in the following thread Batch Conversion of Single-Page TIFF images to Multi-Page PDF.
User avatar
xnview
Author of XnView
Posts: 45247
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: Filelist input - Support for tab-separated and CSV list formats

Post by xnview »

so a CSV with output filename, first & last filename like in the topic?
Pierre.
cday
XnThusiast
Posts: 4238
Joined: Sun Apr 29, 2012 9:45 am
Location: Cheltenham, U.K.

Re: Filelist input - Support for tab-separated and CSV list formats

Post by cday »

xnview wrote: Fri Nov 19, 2021 11:44 am so a CSV with output filename, first & last filename like in the topic?
Two separate issues in separate threads:

o When source files are read from a filelist -l, the output filename with the %% option selected should be the filelist name, not the name of the first file in the filelist;

o A request to add support for reading a filelist formatted as 'tab delimited' and/or as 'comma delimited'.

The envisioned 'use case' is to read the value of cells exported from an Excel chart.

For reference, Excel 2010 (the only version I have) supports saving the value of selected cells to the following formats:

o Text (Tab delimited) (*.txt)
o CSV (Comma delimited) (*.csv)

Support for either option would enable output from an Excel chart to be used as input, but if .csv is a more widely supported format, I'm not sure, a new option for that might be the better solution.
User avatar
xnview
Author of XnView
Posts: 45247
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: Filelist input - Support for tab-separated and CSV list formats

Post by xnview »

so something like
output1.pdf, file1.jpg, file2.jpg
output2.pdf, file3.jpg, file4.jpg
Pierre.
cday
XnThusiast
Posts: 4238
Joined: Sun Apr 29, 2012 9:45 am
Location: Cheltenham, U.K.

Re: Filelist input - Support for tab-separated and CSV list formats

Post by cday »

I am not sure whether we are thinking the same thing or not... :?:

When this code is run:

Code: Select all

nconvert -out pdf -multi -o Output\%%.pdf -l Filelist_1.txt
With the input file Filelist_1.txt:

Code: Select all

Image_1.jpg
Image_2.jpg
Image_3.jpg
The desired output filename is Filelist_1.pdf not the present output filename Image_1.pdf, a bug you previously accepted.

The request is to extend filelist input support (for output from Excel, for example) to either add support for 'tab delimited' input, for example Filelist_2.txt:

Fillelist_2.txt

Code: Select all

Image_1.jpg	Image_2.jpg	Image_3.jpg

Or, possibly better, to add support for comma-delimited CSV format filelist input, for example Filelist_3.csv:

Filelist_3.csv

Code: Select all

Image_1.jpg,Image_2.jpg,Image_3.jpg
Yes, a clear head is needed... :D

I can provide test filelists and images if it would help.
cday
XnThusiast
Posts: 4238
Joined: Sun Apr 29, 2012 9:45 am
Location: Cheltenham, U.K.

Re: Filelist input - Support for tab-separated and CSV list formats

Post by cday »

@Pierre: Not implemented in the new NConvert 7.98? I haven't tested, but no indication of extended support in the help file.

With input from a filelist supported for some time now, it would be good to extend support to at least one of the 'tab-separated' and 'CSV' formats that can be exported from an MS Excel spreadsheet, when you have time...
User avatar
xnview
Author of XnView
Posts: 45247
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: Filelist input - Support for tab-separated and CSV list formats

Post by xnview »

cday wrote: Wed Nov 24, 2021 8:25 pm @Pierre: Not implemented in the new NConvert 7.98? I haven't tested, but no indication of extended support in the help file.
right not yet implemented
Pierre.