chilly_bang wrote: ↑Wed May 16, 2018 4:44 pm
@cday - i'm not very comfortable with NConvert scripting. Would you say, the code at this url:
http://www.netikka.net/tsneti/info/tscmd137.htm would be useful for the task i described? I'm interesting specially for usage of temp file as the source of image dimensions
Let me say first that although I've been a Window user since 3.11, I never really expected to use the command line: I've become moderately familiar with NConvert, but my scripting experience is limited to using a very small subset of cmd.exe ('DOS') in batch files.
At a quick look, the code you posted illustrates among other things the use of variables defined by the SET lines, but doesn't directly relate to the core issue of reading a CSV file and getting parameters in it into variables. The filelist parameter in NConvert is provided to enable input files to be read from a text file list, rather than listed sequentially as the last item at the right end of the command line, so is not directly relevant.
I've only had a quick look, but don't see it solving the core problem. Depending on your own level of experience, you might if necessary concentrate first on getting selected values in a CSV file into 'DOS' variables. You might try some Googling in the hope of finding a solution quickly, otherwise posting just that core part of the problem on one of the general programming forums would seem to be the way forward.
Note: It might be as well to check first that NConvert will indeed accept a 'DOS' variable as an input file name in a command line, I can't easily check immediately as I'm out of the house and on Linux.
Edit:
I've checked and NConvert will accept input file names as 'DOS' variables.
You therefore need to find a way of placing the CSV parameters you need into 'DOS' variables, which can then be used in an NConvert command line in a batch file. Once you can do that for a single image you will presumably need to elaborate that for multiple files, which may require a loop.
Out of interest, what is the structure of the CSV files you need to read?