It's a text filter that can parse CSV style input (multiple values per row separated with ";" semicolons) and generate text based on a template applied per input row
Download: TemplateFilter_20100930.zip
Instructions:
Template format:
* The example batch file is the following:
dir /b | TemplateFilter TestTemplate.txt > TestOutput.html start TestOutput.html @pause
* The example template (to create an HTML link for each filename returned by "dir /b" [b=bare mode] command) is as follows:
<a href="%1">%1</a><br />
%1, %2, etc. in the template text are placeholders for column values of each input row - columns are separated by ";", however you could modify the code to change this or add a 2nd command-line parameter for the caller to define the separator character
Source code:
Source code in Object Pascal / Delphi (the .DPR file holds the Delphi command-line project code) included
(C)opyright 2010 - Zoomicon / George Birbilis
Free to use / give due credit