Page 1 of 1

Prefer one file over another

Posted: Thu Apr 20, 2017 6:10 pm
by web3dprint
We're stuck trying to find a solution to this problem: at some point in our flow, as input we receive many job files, we group them by a string in their name (which is our internal job name) and often one job has a standard file, other times it can also have a file with a "_VDP" in the file name. We would like to proceed with only one of them, in the case of files with "_VDP" it should be that, otherwise it should fallback to the file without "_VDP".

I tried sorting the job files with a search pattern looking for "_VDP", but then I cannot filter on the output looking at the prefix via regex because it's not always 00001_, it's an incremental number between jobs.

Basically I'd like to take only the first file, or as described above the one with "_VDP" in it.
Any ideas? We don't have the Scripting Module, btw.

Re: Prefer one file over another

Posted: Fri Apr 21, 2017 4:59 pm
by gabrielp
If the files are assembled into a folder, there is a Switch variable that displays all of the files in a job directory. I forget the name. But you could search on that for _VDP, and if it exists, route it to a path that knows to look for that file. Otherwise, route it elsewhere.